summaryrefslogtreecommitdiff
path: root/src/evdev-mt-touchpad-thumb.c
diff options
context:
space:
mode:
authorMatt Mayfield <mdmayfield@users.noreply.github.com>2019-07-11 10:14:37 -0500
committerPeter Hutterer <peter.hutterer@who-t.net>2019-07-17 09:33:14 +1000
commitc284d4aaf07c6ec9fe0dd5bcada94e173090f8c2 (patch)
treec3f1cd288d53bdedb862f073e24f246a660d78be /src/evdev-mt-touchpad-thumb.c
parent35fd6e6c4e46940e8e2322afbb078675dc710b80 (diff)
downloadlibinput-c284d4aaf07c6ec9fe0dd5bcada94e173090f8c2.tar.gz
touchpad: stricter thumb detection if no pressure/size
Diffstat (limited to 'src/evdev-mt-touchpad-thumb.c')
-rw-r--r--src/evdev-mt-touchpad-thumb.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/evdev-mt-touchpad-thumb.c b/src/evdev-mt-touchpad-thumb.c
index e62c78c8..eb20616a 100644
--- a/src/evdev-mt-touchpad-thumb.c
+++ b/src/evdev-mt-touchpad-thumb.c
@@ -113,10 +113,12 @@ tp_thumb_detect_pressure_size(const struct tp_dispatch *tp,
static bool
tp_thumb_needs_jail(const struct tp_dispatch *tp, const struct tp_touch *t)
{
- if (t->point.y < tp->thumb.upper_thumb_line)
+ if (t->point.y < tp->thumb.upper_thumb_line ||
+ tp->scroll.method == LIBINPUT_CONFIG_SCROLL_EDGE)
return false;
if (!tp_thumb_in_exclusion_area(tp, t) &&
+ (tp->thumb.use_size || tp->thumb.use_pressure) &&
!tp_thumb_detect_pressure_size(tp, t))
return false;