aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Luc Lamadon <jean-luc.lamadon@nokia.com>2009-10-29 13:04:37 +0200
committerJean-Luc Lamadon <jean-luc.lamadon@nokia.com>2009-10-29 13:04:37 +0200
commite9b23c56859c7ac9766530d09125ce62a38dd5d5 (patch)
treecbde324f4c1104235377108fa799e1ed6fbd0725
parentccd1b18637f10e06056162c90f6fc216974536e8 (diff)
parentf742093e36ebacc2ec8f8134f8bea0438e1e1943 (diff)
Merge branch 'protocol_chge_provider' of git@gitorious.org:maemo-af/contextkit into protocol_chge_provider
-rw-r--r--libcontextprovider/src/propertyadaptor.cpp12
1 files changed, 4 insertions, 8 deletions
diff --git a/libcontextprovider/src/propertyadaptor.cpp b/libcontextprovider/src/propertyadaptor.cpp
index 1751ab7e..65ddc577 100644
--- a/libcontextprovider/src/propertyadaptor.cpp
+++ b/libcontextprovider/src/propertyadaptor.cpp
@@ -50,15 +50,11 @@ PropertyAdaptor::PropertyAdaptor(PropertyPrivate* propertyPrivate, QDBusConnecti
sconnect(propertyPrivate, SIGNAL(valueChanged(const QVariantList&, const quint64&)),
this, SIGNAL(ValueChanged(const QVariantList&, const quint64&)));
- // The same value can be provided on session and system bus by
- // different providers. Unfortunately, each provider needs both a
- // system bus connection and a session bus connection to listen to
- // other providers.
- QDBusConnection::sessionBus().connect("", objectPath(), DBUS_INTERFACE, "ValueChanged",
+ // Start listening to ValueChanged signals. We only listen to the
+ // same bus we're on: that means if the same property is provided
+ // both on session and on system bus, overhearing won't work.
+ connection->connect("", objectPath(), DBUS_INTERFACE, "ValueChanged",
this, SLOT(onValueChanged(QVariantList, quint64)));
-
- QDBusConnection::systemBus().connect("", objectPath(), DBUS_INTERFACE, "ValueChanged",
- this, SLOT(onValueChanged(QVariantList, quint64)));
}
/// Implementation of the D-Bus method Subscribe