aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2012-02-03 20:34:52 -0600
committerTed Gould <ted@gould.cx>2012-02-03 20:34:52 -0600
commit3ceb0322953f0ddfb7fe69ae703ac5c775a7fe00 (patch)
tree8c4ab1a1a11b1389b3a67b3e9bf5ac7a8163b204
parent1b2a4572a83b8e876bc7612e4dc7c913a82f1bd3 (diff)
downloadayatana-indicator-application-3ceb0322953f0ddfb7fe69ae703ac5c775a7fe00.tar.gz
ayatana-indicator-application-3ceb0322953f0ddfb7fe69ae703ac5c775a7fe00.tar.bz2
ayatana-indicator-application-3ceb0322953f0ddfb7fe69ae703ac5c775a7fe00.zip
Adding in service versions to detect the dbus API change
-rw-r--r--src/application-service.c2
-rw-r--r--src/dbus-shared.h1
-rw-r--r--src/indicator-application.c2
3 files changed, 3 insertions, 2 deletions
diff --git a/src/application-service.c b/src/application-service.c
index 68ac264..bc1787f 100644
--- a/src/application-service.c
+++ b/src/application-service.c
@@ -55,7 +55,7 @@ main (int argc, char ** argv)
g_type_init();
/* Bring us up as a basic indicator service */
- service = indicator_service_new(INDICATOR_APPLICATION_DBUS_ADDR);
+ service = indicator_service_new_version(INDICATOR_APPLICATION_DBUS_ADDR, INDICATOR_APPLICATION_SERVICE_VERSION);
g_signal_connect(G_OBJECT(service), INDICATOR_SERVICE_SIGNAL_SHUTDOWN, G_CALLBACK(service_disconnected), NULL);
/* Building our app store */
diff --git a/src/dbus-shared.h b/src/dbus-shared.h
index 6144b9b..ce27bd9 100644
--- a/src/dbus-shared.h
+++ b/src/dbus-shared.h
@@ -23,6 +23,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>.
#define INDICATOR_APPLICATION_DBUS_ADDR "com.canonical.indicator.application"
#define INDICATOR_APPLICATION_DBUS_OBJ "/com/canonical/indicator/application/service"
#define INDICATOR_APPLICATION_DBUS_IFACE "com.canonical.indicator.application.service"
+#define INDICATOR_APPLICATION_SERVICE_VERSION 2
#define NOTIFICATION_WATCHER_DBUS_ADDR "org.kde.StatusNotifierWatcher"
#define NOTIFICATION_WATCHER_DBUS_OBJ "/StatusNotifierWatcher"
diff --git a/src/indicator-application.c b/src/indicator-application.c
index 173124c..d515e34 100644
--- a/src/indicator-application.c
+++ b/src/indicator-application.c
@@ -158,7 +158,7 @@ indicator_application_init (IndicatorApplication *self)
priv->theme_dirs = NULL;
priv->disconnect_kill = 0;
- priv->sm = indicator_service_manager_new(INDICATOR_APPLICATION_DBUS_ADDR);
+ priv->sm = indicator_service_manager_new_version(INDICATOR_APPLICATION_DBUS_ADDR, INDICATOR_APPLICATION_SERVICE_VERSION);
g_signal_connect(G_OBJECT(priv->sm), INDICATOR_SERVICE_MANAGER_SIGNAL_CONNECTION_CHANGE, G_CALLBACK(connection_changed), self);
priv->applications = NULL;