[metacity/wip/muktupavels/issue-20: 2/2] session: always finish interaction




commit 43669165559ead4da7e1021bc132e85856b78894
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Mon Jul 19 11:56:14 2021 +0300

    session: always finish interaction
    
    After commits 0b3f45bb1bf8 and db37deb589ea SmcInteractDone and
    SmcSaveYourselfDone is only called if zenity dialog exits with 0
    code.
    
    Finish interaction also when dialog is closed by pressing Cancel
    indicating that shutdown should be canceled.
    
    https://gitlab.gnome.org/GNOME/metacity/-/issues/20

 src/core/session.c | 5 +++++
 1 file changed, 5 insertions(+)
---
diff --git a/src/core/session.c b/src/core/session.c
index 38b41d01..f7b137b2 100644
--- a/src/core/session.c
+++ b/src/core/session.c
@@ -1774,6 +1774,11 @@ dialog_closed (GPid pid, int status, gpointer user_data)
     {
       finish_interact (shutdown);
     }
+  else
+    {
+      SmcInteractDone (session_connection, shutdown ? True : False);
+      save_yourself_possibly_done (shutdown, FALSE);
+    }
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]