From: Konstantin Kharlamov <hi-an...@yandex.ru>

Signed-off-by: Konstantin Kharlamov <hi-an...@yandex.ru>
Signed-off-by: Peter Hutterer <peter.hutte...@who-t.net>
---
Changes to v3:
- rebased for patch 1/3

 src/evdev-mt-touchpad.c | 21 +--------------------
 1 file changed, 1 insertion(+), 20 deletions(-)

diff --git a/src/evdev-mt-touchpad.c b/src/evdev-mt-touchpad.c
index 75344661..0c3e6a2b 100644
--- a/src/evdev-mt-touchpad.c
+++ b/src/evdev-mt-touchpad.c
@@ -135,22 +135,6 @@ tp_motion_history_push(struct tp_touch *t)
        t->history.index = motion_index;
 }
 
-static inline void
-tp_maybe_disable_hysteresis(struct tp_dispatch *tp, uint64_t time)
-{
-       /* If the finger is down for 80ms without seeing motion events,
-          the firmware filters and we don't need a software hysteresis */
-       if (tp->nfingers_down >= 1 &&
-           time - tp->hysteresis.last_motion_time > ms2us(80)) {
-               tp->hysteresis.enabled = false;
-               evdev_log_debug(tp->device, "hysteresis disabled\n");
-               return;
-       }
-
-       if (tp->queued & TOUCHPAD_EVENT_MOTION)
-               tp->hysteresis.last_motion_time = time;
-}
-
 static inline void
 tp_motion_hysteresis(struct tp_dispatch *tp,
                     struct tp_touch *t)
@@ -1583,9 +1567,6 @@ static void
 tp_handle_state(struct tp_dispatch *tp,
                uint64_t time)
 {
-       if (tp->hysteresis.enabled)
-               tp_maybe_disable_hysteresis(tp, time);
-
        tp_process_state(tp, time);
        tp_post_events(tp, time);
        tp_post_process_state(tp, time);
@@ -3016,7 +2997,7 @@ tp_init_hysteresis(struct tp_dispatch *tp)
        res_y = tp->device->abs.absinfo_y->resolution;
        tp->hysteresis.margin.x = res_x/2;
        tp->hysteresis.margin.y = res_y/2;
-       tp->hysteresis.enabled = true;
+       tp->hysteresis.enabled = false;
 }
 
 static void
-- 
2.14.3

_______________________________________________
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-devel

Reply via email to