From cedf3aeb1c63ac91f550dd48f984cf4f6cf68ed7 Mon Sep 17 00:00:00 2001 From: Jules Aguillon Date: Sun, 17 Aug 2025 19:24:08 +0200 Subject: Slider sensitivity option and improve slider ergonimics (#1070) * Add option 'Space bar slider sensitivity' * Fix slider moving the cursor twice at the beginning The slider was generating two events when first activated. Since 2bed42857. * Make slider less sensitive for the first step This moves the second slider step approximately 40% further and takes the new sensitivity option into account. Allows moving the cursor by one spot more easily.--- srcs/juloo.keyboard2/Pointers.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'srcs/juloo.keyboard2/Pointers.java') diff --git a/srcs/juloo.keyboard2/Pointers.java b/srcs/juloo.keyboard2/Pointers.java index 90cfc28..62fdbb8 100644 --- a/srcs/juloo.keyboard2/Pointers.java +++ b/srcs/juloo.keyboard2/Pointers.java @@ -473,7 +473,6 @@ public final class Pointers implements Handler.Callback stopLongPress(ptr); ptr.flags |= FLAG_P_SLIDING; ptr.sliding = new Sliding(x, y, dirx, diry, kv.getSlider()); - _handler.onPointerDown(kv, true); } /** Return the [FLAG_P_*] flags that correspond to pressing [kv]. */ @@ -622,7 +621,7 @@ public final class Pointers implements Handler.Callback float travelled = Math.abs(x - last_x) + Math.abs(y - last_y); if (last_move_ms == -1) { - if (travelled < _config.swipe_dist_px) + if (travelled < (_config.swipe_dist_px + _config.slide_step_px)) return; last_move_ms = System.currentTimeMillis(); } -- cgit v1.2.3