[gimp] app: give focus back to quit dialog after changing active shell.



commit 3943d9fe636dfb3d37489ac0f0a71259d781e133
Author: Jehan <jehan girinstud io>
Date:   Sun Oct 2 04:10:26 2016 +0200

    app: give focus back to quit dialog after changing active shell.
    
    Otherwise keyboard interaction (like hitting Escape or ctrl-d) ends up
    broken and you may not realize immediately the dialog lost focus since
    it is still the top window.

 app/dialogs/quit-dialog.c |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/app/dialogs/quit-dialog.c b/app/dialogs/quit-dialog.c
index 42db6f6..a8479d4 100644
--- a/app/dialogs/quit-dialog.c
+++ b/app/dialogs/quit-dialog.c
@@ -413,7 +413,12 @@ quit_close_all_dialog_image_activated (GimpContainerView *view,
       GimpDisplay *display = list->data;
 
       if (gimp_display_get_image (display) == image)
-        gimp_display_shell_present (gimp_display_get_shell (display));
+        {
+          gimp_display_shell_present (gimp_display_get_shell (display));
+          /* We only want to update the active shell. Give back keyboard
+           * focus to the quit dialog after this. */
+          gtk_window_present (GTK_WINDOW (dialog->dialog));
+        }
     }
 }
 


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