summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2013-03-04 11:23:46 -0500
committerRay Strode <rstrode@redhat.com>2013-03-04 11:57:17 -0500
commit377e2ed8a5f694ee937f39e12e7239645b2bf209 (patch)
treeebfe5dc6979b294fcb8fdbf30074c895f114f601 /src
parent99cfbac473f455fb08e232c8de6625b8ca277371 (diff)
downloadmutter-377e2ed8a5f694ee937f39e12e7239645b2bf209.tar.gz
keybindings: filter overlay key even when not-modal
mutter currently only filters the overlay key through the shell when there is a grab operation and that grab operation belongs to the shell (because the shell is pushModal'd). This means the shell can't filter out overlay key press events events at startup (since the shell isn't normally modal). This commit changes the code to always run the shell filtering code, even when the shell is not modal. https://bugzilla.gnome.org/show_bug.cgi?id=694837
Diffstat (limited to 'src')
-rw-r--r--src/core/keybindings.c20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/core/keybindings.c b/src/core/keybindings.c
index b3bb1cecc..bfc16a73d 100644
--- a/src/core/keybindings.c
+++ b/src/core/keybindings.c
@@ -1707,23 +1707,21 @@ process_overlay_key (MetaDisplay *display,
}
else if (event->evtype == XI_KeyRelease)
{
+ MetaKeyBinding *binding;
+
display->overlay_key_only_pressed = FALSE;
/* We want to unfreeze events, but keep the grab so that if the user
* starts typing into the overlay we get all the keys */
XIAllowEvents (display->xdisplay, event->deviceid,
XIAsyncDevice, event->time);
- if (display->grab_op == META_GRAB_OP_COMPOSITOR)
- {
- MetaKeyBinding *binding =
- display_get_keybinding (display,
- display->overlay_key_combo.keysym,
- display->overlay_key_combo.keycode,
- display->grab_mask);
- if (binding &&
- meta_compositor_filter_keybinding (display->compositor, screen, binding))
- return TRUE;
- }
+ binding = display_get_keybinding (display,
+ display->overlay_key_combo.keysym,
+ display->overlay_key_combo.keycode,
+ display->grab_mask);
+ if (binding &&
+ meta_compositor_filter_keybinding (display->compositor, screen, binding))
+ return TRUE;
meta_display_overlay_key_activate (display);
}