From 4759a380da77dd1f8746f298a5ae051319a70ddd Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Tue, 20 Aug 2013 08:42:24 -0500 Subject: when switching to the guest session, explicitly lock the current users's session --- src/backend-dbus/actions.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'src/backend-dbus') diff --git a/src/backend-dbus/actions.c b/src/backend-dbus/actions.c index 9030ca7..17547f0 100644 --- a/src/backend-dbus/actions.c +++ b/src/backend-dbus/actions.c @@ -734,7 +734,7 @@ my_about (IndicatorSessionActions * self G_GNUC_UNUSED) ***/ static void -my_switch_to_screensaver (IndicatorSessionActions * self) +lock_current_session (IndicatorSessionActions * self) { priv_t * p = INDICATOR_SESSION_ACTIONS_DBUS(self)->priv; @@ -743,6 +743,12 @@ my_switch_to_screensaver (IndicatorSessionActions * self) gnome_screen_saver_call_lock (p->screen_saver, p->cancellable, NULL, NULL); } +static void +my_switch_to_screensaver (IndicatorSessionActions * self) +{ + lock_current_session (self); +} + static void my_switch_to_greeter (IndicatorSessionActions * self) { @@ -750,6 +756,7 @@ my_switch_to_greeter (IndicatorSessionActions * self) g_return_if_fail (p->dm_seat != NULL); + /* show the greeter */ display_manager_seat_call_switch_to_greeter (p->dm_seat, p->dm_seat_cancellable, NULL, NULL); @@ -762,6 +769,8 @@ my_switch_to_guest (IndicatorSessionActions * self) g_return_if_fail (p->dm_seat != NULL); + lock_current_session (self); + display_manager_seat_call_switch_to_guest (p->dm_seat, "", p->dm_seat_cancellable, NULL, NULL); -- cgit v1.2.3