From 9ed76b24fb6842cdb5b0ac3a734f150c5514a092 Mon Sep 17 00:00:00 2001 From: "Peter F. Patel-Schneider" Date: Mon, 18 Apr 2022 08:17:41 -0400 Subject: [PATCH] rules: fix bug in xtest mouse scrolling --- lib/logitech_receiver/diversion.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/logitech_receiver/diversion.py b/lib/logitech_receiver/diversion.py index 85fbf9d1..61ae8d96 100644 --- a/lib/logitech_receiver/diversion.py +++ b/lib/logitech_receiver/diversion.py @@ -322,9 +322,9 @@ def simulate_scroll(dx, dy): if not wayland and xtest_available: success = True if dx: - success = click(7 if dx > 0 else 6, count=abs(dx)) + success = click_xtest(buttons['scroll_right' if dx > 0 else 'scroll_left'], count=abs(dx)) if dy and success: - success = click(4 if dy > 0 else 5, count=abs(dy)) + success = click_xtest(buttons['scroll_up' if dy > 0 else 'scroll_down'], count=abs(dy)) if success: return True if setup_uinput():