diff options
author | Conor Curran <conor.curran@canonical.com> | 2011-08-09 09:59:20 +0100 |
---|---|---|
committer | Conor Curran <conor.curran@canonical.com> | 2011-08-09 09:59:20 +0100 |
commit | 853ad495b863c179792044f1a74e8556d04e32db (patch) | |
tree | 8c8ac5869ebb4908f537e05f28db27261dabd180 /src/session-dbus.c | |
parent | 3edbdc147bcf6ce1b94e6156e318728c41abea2a (diff) | |
download | ayatana-indicator-session-853ad495b863c179792044f1a74e8556d04e32db.tar.gz ayatana-indicator-session-853ad495b863c179792044f1a74e8556d04e32db.tar.bz2 ayatana-indicator-session-853ad495b863c179792044f1a74e8556d04e32db.zip |
and the actual code
Diffstat (limited to 'src/session-dbus.c')
-rw-r--r-- | src/session-dbus.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/session-dbus.c b/src/session-dbus.c index 9aa75ef..1cf73ac 100644 --- a/src/session-dbus.c +++ b/src/session-dbus.c @@ -293,3 +293,25 @@ session_dbus_set_user_menu_visibility (SessionDbus* session, } } } + +void session_dbus_restart_required (SessionDbus* session) +{ + SessionDbusPrivate * priv = SESSION_DBUS_GET_PRIVATE(session); + GError * error = NULL; + + if (priv->bus != NULL) { + g_dbus_connection_emit_signal (priv->bus, + NULL, + INDICATOR_SESSION_SERVICE_DBUS_OBJECT, + INDICATOR_SESSION_SERVICE_DBUS_IFACE, + "RebootRequired", + NULL, + &error); + + if (error != NULL) { + g_warning("Unable to send reboot-required signal: %s", error->message); + g_error_free(error); + } + } + +} |