[libdazzle/libdazzle-3-26] shortcuts: activate mnemonics for the window



commit fd4c7359f4cd98ed6dfad59d9a7daf51d805f27c
Author: Christian Hergert <chergert redhat com>
Date:   Wed Jan 10 13:44:08 2018 -0800

    shortcuts: activate mnemonics for the window
    
    This checks to see if we have a mnemonic visible in the fallback activation
    path. This fixes an issue where mnemonics were visible but not activated.
    
    # Conflicts:
    #   src/shortcuts/dzl-shortcut-manager.c

 src/shortcuts/dzl-shortcut-manager.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/shortcuts/dzl-shortcut-manager.c b/src/shortcuts/dzl-shortcut-manager.c
index be047ce..35c5e7a 100644
--- a/src/shortcuts/dzl-shortcut-manager.c
+++ b/src/shortcuts/dzl-shortcut-manager.c
@@ -821,6 +821,11 @@ dzl_shortcut_manager_run_fallbacks (DzlShortcutManager     *self,
       if (gtk_bindings_activate (G_OBJECT (toplevel), keyval, state))
         return TRUE;
 
+      /* See if there is a mnemonic active that should be activated */
+      if (GTK_IS_WINDOW (toplevel) &&
+          gtk_window_mnemonic_activate (GTK_WINDOW (toplevel), keyval, state))
+        return TRUE;
+
       if (GTK_IS_APPLICATION (app))
         {
           g_autofree gchar *accel = dzl_shortcut_chord_to_string (chord);


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