diff options
author | José Expósito <jose.exposito89@gmail.com> | 2021-11-02 19:37:07 +0100 |
---|---|---|
committer | José Expósito <jose.exposito89@gmail.com> | 2021-11-04 18:40:54 +0100 |
commit | 5e44861e0ed7fdb447170a03adb9ff361ae6e4ce (patch) | |
tree | 5ac50984cc99f8677640e07bc7cee4d2c04e05e5 /src | |
parent | be3c09bc1562b20db3e6533ab2e3347d05376a11 (diff) |
gestures: cancel hold gestures on thumb detection
Before hold gestures where implemented, when a thumb was detected it
was enough to reset the state machine.
However, now it is possible to detect a thumb while a hold gesture is
in course.
Cancel any ongoing gesture when a thumb is detected to avoid dropping
the gesture end event.
See #693
Signed-off-by: José Expósito <jose.exposito89@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/evdev-mt-touchpad-gestures.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/evdev-mt-touchpad-gestures.c b/src/evdev-mt-touchpad-gestures.c index a9f4644c..c933bb0f 100644 --- a/src/evdev-mt-touchpad-gestures.c +++ b/src/evdev-mt-touchpad-gestures.c @@ -958,7 +958,7 @@ tp_gesture_detect_motion_gestures(struct tp_dispatch *tp, uint64_t time) */ if (tp->thumb.detect_thumbs && thumb_mm < min_move) { tp_thumb_suppress(tp, thumb); - tp_gesture_handle_event(tp, GESTURE_EVENT_RESET, time); + tp_gesture_cancel(tp, time); return; } |