[SCM] ktp-common-internals packaging branch, master, updated. debian/15.12.1-2-1839-gf0635e9

Maximiliano Curia maxy at moszumanska.debian.org
Mon May 9 09:05:20 UTC 2016


Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-common-internals.git;a=commitdiff;h=ff5a027

The following commit has been merged in the master branch:
commit ff5a0270715e5a64c163c654c49e4cd878fa4072
Author: George Kiagiadakis <kiagiadakis.george at gmail.com>
Date:   Sun Jul 1 17:56:02 2012 +0300

    DebugMessagesModel: Disable monitoring of the service on destruction
    
    Emiting this signal from a service is expensive and therefore
    it should be disabled when it is no longer needed.
---
 tools/debugger/debug-messages-model.cpp | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/tools/debugger/debug-messages-model.cpp b/tools/debugger/debug-messages-model.cpp
index 1716a3e..07f9323 100644
--- a/tools/debugger/debug-messages-model.cpp
+++ b/tools/debugger/debug-messages-model.cpp
@@ -39,6 +39,13 @@ DebugMessagesModel::DebugMessagesModel(const QString & service, QObject *parent)
 
 DebugMessagesModel::~DebugMessagesModel()
 {
+    if (m_debugReceiver && m_ready) {
+        //disable monitoring and do it synchronously before all the objects are destroyed
+        Tp::PendingOperation *op = m_debugReceiver->setMonitoringEnabled(false);
+        QEventLoop loop;
+        connect(op, SIGNAL(finished(Tp::PendingOperation*)), &loop, SLOT(quit()));
+        loop.exec();
+    }
 }
 
 void DebugMessagesModel::onServiceRegistered(const QString & service)

-- 
ktp-common-internals packaging



More information about the pkg-kde-commits mailing list