diff options
author | Ted Gould <ted@gould.cx> | 2010-03-12 17:36:22 -0600 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2010-03-12 17:36:22 -0600 |
commit | 6bdd9dd9b36a0082d207fb6963c3f47262f457af (patch) | |
tree | a2721688f0df986ddef9bd8287d723dc252f6588 /src/session-service.c | |
parent | 7f489865a78b866ce22627c3ac5fb224a8bec4d1 (diff) | |
parent | 62a79745a976eb7459a9f3aaeb9f6fa7e021897f (diff) | |
download | ayatana-indicator-session-6bdd9dd9b36a0082d207fb6963c3f47262f457af.tar.gz ayatana-indicator-session-6bdd9dd9b36a0082d207fb6963c3f47262f457af.tar.bz2 ayatana-indicator-session-6bdd9dd9b36a0082d207fb6963c3f47262f457af.zip |
Merging in the panel restart icon branch
Diffstat (limited to 'src/session-service.c')
-rw-r--r-- | src/session-service.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/session-service.c b/src/session-service.c index 7d21c38..c4df661 100644 --- a/src/session-service.c +++ b/src/session-service.c @@ -43,6 +43,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>. #include "gconf-helper.h" +#include "session-dbus.h" #include "users-service-dbus.h" #include "lock-helper.h" @@ -65,6 +66,7 @@ struct _ActivateData static DBusGConnection *system_bus = NULL; static DBusGProxy *gdm_proxy = NULL; static UsersServiceDbus *dbus_interface = NULL; +static SessionDbus *session_dbus = NULL; static DbusmenuMenuitem *lock_menuitem = NULL; static DbusmenuMenuitem *switch_menuitem = NULL; @@ -621,6 +623,9 @@ restart_dir_changed (void) dbusmenu_menuitem_property_set(restart_mi, RESTART_ITEM_LABEL, _("Restart Required...")); } dbusmenu_menuitem_property_set(restart_mi, RESTART_ITEM_ICON, "system-restart-panel"); + if (session_dbus != NULL) { + session_dbus_set_name(session_dbus, ICON_RESTART); + } } else { if (supress_confirmations()) { dbusmenu_menuitem_property_set(restart_mi, RESTART_ITEM_LABEL, _("Restart")); @@ -628,6 +633,9 @@ restart_dir_changed (void) dbusmenu_menuitem_property_set(restart_mi, RESTART_ITEM_LABEL, _("Restart...")); } dbusmenu_menuitem_property_remove(restart_mi, RESTART_ITEM_ICON); + if (session_dbus != NULL) { + session_dbus_set_name(session_dbus, ICON_DEFAULT); + } } return; @@ -667,6 +675,8 @@ main (int argc, char ** argv) INDICATOR_SERVICE_SIGNAL_SHUTDOWN, G_CALLBACK(service_shutdown), NULL); + session_dbus = session_dbus_new(); + g_idle_add(lock_screen_setup, NULL); root_menuitem = dbusmenu_menuitem_new(); |