[mutter] clutter/input-pointer-a11y: Fix dwell timeout start after moving pointer



commit 9b3b5badfbbe004115003fead50d7eb2c47dc33d
Author: Jonas Dreßler <verdre v0yd nl>
Date:   Thu Aug 22 11:40:46 2019 +0200

    clutter/input-pointer-a11y: Fix dwell timeout start after moving pointer
    
    Sometimes the dwell timeout doesn't start again after quickly moving the
    pointer. That happens if `should_stop_dwell` returns TRUE for the last
    motion event we receive: It will stop the current timeout, but not start
    a new one until we receive another event where the moved distance is
    smaller than the threshold.
    
    To fix this, always call `should_start_dwell` and `start_dwell_timeout`
    instead of using an else-block, this makes sure we start a new dwell
    timeout still during the same motion event that stopped the old one.
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/746

 clutter/clutter/clutter-input-pointer-a11y.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/clutter/clutter/clutter-input-pointer-a11y.c b/clutter/clutter/clutter-input-pointer-a11y.c
index c2b42e00a..0e7c5847b 100644
--- a/clutter/clutter/clutter-input-pointer-a11y.c
+++ b/clutter/clutter/clutter-input-pointer-a11y.c
@@ -599,7 +599,8 @@ _clutter_input_pointer_a11y_on_motion_event (ClutterInputDevice *device,
     {
       if (should_stop_dwell (device))
         stop_dwell_timeout (device);
-      else if (should_start_dwell (device))
+
+      if (should_start_dwell (device))
         start_dwell_timeout (device);
     }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]