summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Garnacho <carlosg@gnome.org>2022-01-26 15:59:36 +0100
committerCarlos Garnacho <carlosg@gnome.org>2022-01-26 15:59:36 +0100
commit8e86e6325b4138a8ef0bb4ab8ef77627e6da3e03 (patch)
treebde6bb4d67b1f56b07c93b770f6e4a2ee2b10615
parent2b41e72196ee648ae71f8c8af393d8d8942ea0d4 (diff)
downloadgtk+-8e86e6325b4138a8ef0bb4ab8ef77627e6da3e03.tar.gz
gtk/main: Do not use touchpad event sequence for pointer focus lookup
Despite touchpad gestures having a sequence, these must use the logical pointer focus. Avoid using the sequence for GtkPointerFocus lookups with those events, in order to ensure those events make it all the way to the intended target. This is fallout from adding GdkEventSequence information to touchpad gestures.
-rw-r--r--gtk/gtkmain.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gtk/gtkmain.c b/gtk/gtkmain.c
index c96bfb3c81..bfab35ad61 100644
--- a/gtk/gtkmain.c
+++ b/gtk/gtkmain.c
@@ -1352,6 +1352,14 @@ handle_pointing_event (GdkEvent *event)
*/
device = gdk_seat_get_pointer (gdk_event_get_seat (event));
}
+ else if (type == GDK_TOUCHPAD_PINCH ||
+ type == GDK_TOUCHPAD_SWIPE)
+ {
+ /* Another bit of a kludge, touchpad gesture sequences do not
+ * reflect on the pointer focus lookup.
+ */
+ sequence = NULL;
+ }
switch ((guint) type)
{