aboutsummaryrefslogtreecommitdiff
path: root/src/service.c
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2013-06-26 11:40:14 -0500
committerCharles Kerr <charles.kerr@canonical.com>2013-06-26 11:40:14 -0500
commit951592e1349e863b721ca32273577e6f1b517d13 (patch)
treec3ac7cbc26babf9ee47ab309f9c7f7f6e3f92715 /src/service.c
parent2d089b9e30b1d292ed8d1a7e84d0a0019aa10784 (diff)
downloadayatana-indicator-session-951592e1349e863b721ca32273577e6f1b517d13.tar.gz
ayatana-indicator-session-951592e1349e863b721ca32273577e6f1b517d13.tar.bz2
ayatana-indicator-session-951592e1349e863b721ca32273577e6f1b517d13.zip
fix regression that displayed the 'restart' button even when prompting was enabled and the user was running Unity
Diffstat (limited to 'src/service.c')
-rw-r--r--src/service.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/service.c b/src/service.c
index 7f90c9c..d8fc961 100644
--- a/src/service.c
+++ b/src/service.c
@@ -539,7 +539,9 @@ create_session_section (IndicatorSessionService * self)
if (indicator_session_actions_can_hibernate (p->backend_actions))
g_menu_append (menu, _("Hibernate"), "indicator.hibernate");
- if (!g_settings_get_boolean (s, "suppress-restart-menuitem"))
+ /* NB: check 'ellipsis' here to skip this item if prompting is enabled
+ because this shows the same prompt as 'Shut Down' in Unity */
+ if (!ellipsis && !g_settings_get_boolean (s, "suppress-restart-menuitem"))
{
const char * label = ellipsis ? _("Restart\342\200\246") : _("Restart");
g_menu_append (menu, label, "indicator.reboot");