[libdazzle/libdazzle-3-30] shorcuts: special case shift+tab for keyboard movement



commit 7586d0ba69e697b325ddc5845cb4f705591ffe48
Author: Christian Hergert <chergert redhat com>
Date:   Fri Sep 28 17:23:41 2018 -0700

    shorcuts: special case shift+tab for keyboard movement
    
    This fixes an issue where shift+tab was not moving backwards through the
    UI elements (while tab worked fine).
    
    Fixes #28

 src/shortcuts/dzl-shortcut-manager.c | 9 +++++++++
 1 file changed, 9 insertions(+)
---
diff --git a/src/shortcuts/dzl-shortcut-manager.c b/src/shortcuts/dzl-shortcut-manager.c
index 8d853dd..797af46 100644
--- a/src/shortcuts/dzl-shortcut-manager.c
+++ b/src/shortcuts/dzl-shortcut-manager.c
@@ -829,6 +829,15 @@ dzl_shortcut_manager_run_fallbacks (DzlShortcutManager     *self,
 
       dzl_shortcut_chord_get_nth_key (chord, 0, &keyval, &state);
 
+      /* Special case shift-tab, which is shown as ISO_Left_Tab when
+       * we converted into a Dazzle chord.
+       */
+      if (keyval == GDK_KEY_ISO_Left_Tab && state == 0)
+        {
+          if (gtk_bindings_activate (G_OBJECT (toplevel), keyval, GDK_SHIFT_MASK))
+            DZL_RETURN (TRUE);
+        }
+
       /* See if the toplevel activates this, like Tab, etc */
       if (gtk_bindings_activate (G_OBJECT (toplevel), keyval, state))
         DZL_RETURN (TRUE);


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