From b412bfe918592d1986743e52d967205395788da3 Mon Sep 17 00:00:00 2001 From: Ted Gould Date: Tue, 12 Jul 2011 10:14:12 -0500 Subject: Adding in a property for being in replace mode --- libindicator/indicator-service.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'libindicator') diff --git a/libindicator/indicator-service.c b/libindicator/indicator-service.c index e5eaa5b..0e87332 100644 --- a/libindicator/indicator-service.c +++ b/libindicator/indicator-service.c @@ -57,6 +57,7 @@ struct _IndicatorServicePrivate { GHashTable * watchers; guint this_service_version; guint dbus_registration; + gboolean replace_mode; }; /* Signals Stuff */ @@ -192,6 +193,7 @@ indicator_service_init (IndicatorService *self) priv->this_service_version = 0; priv->timeout_length = 500; priv->dbus_registration = 0; + priv->replace_mode = FALSE; const gchar * timeoutenv = g_getenv("INDICATOR_SERVICE_SHUTDOWN_TIMEOUT"); if (timeoutenv != NULL) { @@ -202,6 +204,12 @@ indicator_service_init (IndicatorService *self) } } + const gchar * replaceenv = g_getenv("INDICATOR_SERVICE_REPLACE_MODE"); + if (replaceenv != NULL) { + priv->replace_mode = TRUE; + g_debug("Putting into replace mode"); + } + /* NOTE: We're using g_free here because that's what needs to happen, but you really should call watchers_remove first as well since that disconnects the signals. We can't do that with a callback -- cgit v1.2.3