diff -Nru mate-session-manager-1.12.2/debian/changelog mate-session-manager-1.12.2/debian/changelog --- mate-session-manager-1.12.2/debian/changelog 2016-04-08 11:44:38.000000000 +0300 +++ mate-session-manager-1.12.2/debian/changelog 2017-10-29 15:23:50.000000000 +0300 @@ -1,3 +1,10 @@ +mate-session-manager (1.12.2-1ubuntu1) UNRELEASED; urgency=medium + + * fix-quit-dialog-focus.patch: new patch. Don't lose focus + when displaying logout or shutdown dialog. (LP: #1714399) + + -- Vlad Orlov Sun, 29 Oct 2017 15:20:19 +0300 + mate-session-manager (1.12.2-1) unstable; urgency=medium [ Martin Wimpress ] diff -Nru mate-session-manager-1.12.2/debian/patches/fix-quit-dialog-focus.patch mate-session-manager-1.12.2/debian/patches/fix-quit-dialog-focus.patch --- mate-session-manager-1.12.2/debian/patches/fix-quit-dialog-focus.patch 1970-01-01 03:00:00.000000000 +0300 +++ mate-session-manager-1.12.2/debian/patches/fix-quit-dialog-focus.patch 2017-10-29 15:19:10.000000000 +0300 @@ -0,0 +1,44 @@ +From 9e8d8ad24ad1025634b2558bc572937e55c64a2c Mon Sep 17 00:00:00 2001 +From: monsta +Date: Tue, 17 Oct 2017 17:14:21 +0300 +Subject: [PATCH] don't lose focus when displaying logout or shutdown dialog + +same as done in: +https://github.com/mate-desktop/mate-polkit/commit/ed37b52fbfbce5d57d0549fac1a9dca2502f3372 + +fixes https://github.com/mate-desktop/mate-session-manager/issues/123 +fixes https://github.com/mate-desktop/mate-session-manager/issues/140 +--- + mate-session/gsm-manager.c | 5 +++++ + 1 file changed, 5 insertions(+) + +Index: mate-session-manager-1.12.2/mate-session/gsm-manager.c +=================================================================== +--- mate-session-manager-1.12.2.orig/mate-session/gsm-manager.c ++++ mate-session-manager-1.12.2/mate-session/gsm-manager.c +@@ -44,6 +44,7 @@ + + #include /* for logout dialog */ + #include /* for gsettings */ ++#include + + #include "gsm-manager.h" + #include "gsm-manager-glue.h" +@@ -3229,6 +3230,8 @@ show_shutdown_dialog (GsmManager *manage + G_CALLBACK (logout_dialog_response), + manager); + gtk_widget_show (dialog); ++ gtk_window_present_with_time (GTK_WINDOW (dialog), ++ gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (dialog)))); + } + + static void +@@ -3251,6 +3254,8 @@ show_logout_dialog (GsmManager *manager) + G_CALLBACK (logout_dialog_response), + manager); + gtk_widget_show (dialog); ++ gtk_window_present_with_time (GTK_WINDOW (dialog), ++ gdk_x11_get_server_time (gtk_widget_get_window (GTK_WIDGET (dialog)))); + } + + static void diff -Nru mate-session-manager-1.12.2/debian/patches/series mate-session-manager-1.12.2/debian/patches/series --- mate-session-manager-1.12.2/debian/patches/series 2016-01-04 11:27:52.000000000 +0300 +++ mate-session-manager-1.12.2/debian/patches/series 2017-10-29 15:19:03.000000000 +0300 @@ -1,2 +1,3 @@ 1003_typo-fix.patch 0005_lock-session-before-user-switch.patch +fix-quit-dialog-focus.patch