diff options
author | Ted Gould <ted@gould.cx> | 2013-08-15 15:32:36 -0500 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2013-08-15 15:32:36 -0500 |
commit | 190841b5d7262d9619c618e19bcb08e30968fd41 (patch) | |
tree | cf40ed570fb39747b9cb4ce5e071e545a8a1aa96 /src/messages-service.c | |
parent | 86cedd8ccb7c779436f5d9cf0caec90dfef97dd7 (diff) | |
download | ayatana-indicator-messages-190841b5d7262d9619c618e19bcb08e30968fd41.tar.gz ayatana-indicator-messages-190841b5d7262d9619c618e19bcb08e30968fd41.tar.bz2 ayatana-indicator-messages-190841b5d7262d9619c618e19bcb08e30968fd41.zip |
Emit to dbus when the status changes
Diffstat (limited to 'src/messages-service.c')
-rw-r--r-- | src/messages-service.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/messages-service.c b/src/messages-service.c index 6423cd5..71fa09b 100644 --- a/src/messages-service.c +++ b/src/messages-service.c @@ -107,6 +107,13 @@ set_status (IndicatorMessagesService *service, g_object_unref (appinfo); } +/* The status has been set by the user, let's tell the world! */ +static void +status_set_by_user (ImApplicationList * list, const gchar * status, gpointer user_data) +{ + indicator_messages_service_emit_status_changed(messages_service, status); + return; +} static void on_bus_acquired (GDBusConnection *bus, @@ -199,6 +206,8 @@ main (int argc, char ** argv) G_CALLBACK (set_status), NULL); applications = im_application_list_new (); + g_signal_connect (applications, "status-set", + G_CALLBACK (status_set_by_user), NULL); settings = g_settings_new ("com.canonical.indicator.messages"); { |