From a169fe5c78143eb91864c6cee3d9e537834c7c39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marco=20Trevisan=20=28Trevi=C3=B1o=29?= Date: Wed, 6 Mar 2013 13:42:02 +0100 Subject: SessionMenuMgr: call Shutdown method if we're suppressing the dialogs --- src/session-menu-mgr.c | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/session-menu-mgr.c b/src/session-menu-mgr.c index 9010f36..ba82645 100644 --- a/src/session-menu-mgr.c +++ b/src/session-menu-mgr.c @@ -1210,10 +1210,17 @@ action_func_shutdown (SessionMenuMgr * mgr) { if (mgr->shell_mode) { - /* We call 'Reboot' method instead of 'Shutdown' because - * Unity SessionManager handles the Shutdown request as a more - * general request as the default SessionManager dialog would do */ - call_session_manager_method ("Reboot", NULL); + if (g_settings_get_boolean (mgr->indicator_settings, "suppress-logout-restart-shutdown")) + { + call_session_manager_method ("Shutdown", NULL); + } + else + { + /* We call 'Reboot' method instead of 'Shutdown' because + * Unity SessionManager handles the Shutdown request as a more + * general request as the default SessionManager dialog would do */ + call_session_manager_method ("Reboot", NULL); + } } else { -- cgit v1.2.3