From 7310a3fabf8e8dcaee0e791f6e897bcab550555e Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 27 Feb 2018 16:18:20 +1000 Subject: [PATCH libinput] touchpad: don't do speed-based thumb detection on single-touch or semi-mts Because life is too short for this https://bugs.freedesktop.org/show_bug.cgi?id=105265 Signed-off-by: Peter Hutterer --- src/evdev-mt-touchpad.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/evdev-mt-touchpad.c b/src/evdev-mt-touchpad.c index 62ba678e..2a6cdcef 100644 --- a/src/evdev-mt-touchpad.c +++ b/src/evdev-mt-touchpad.c @@ -92,6 +92,10 @@ tp_calculate_motion_speed(struct tp_dispatch *tp, struct tp_touch *t) double distance; double speed; + /* Don't do this on single-touch or semi-mt devices */ + if (!tp->has_mt || tp->semi_mt) + return; + /* This doesn't kick in until we have at least 4 events in the * motion history. As a side-effect, this automatically handles the * 2fg scroll where a finger is down and moving fast before the -- 2.14.3