summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael Marçalo <raroma09@gmail.com>2022-03-26 02:02:18 +0000
committerRafael Marçalo <raroma09@gmail.com>2022-03-26 02:02:18 +0000
commit09c441d397d5bf07dd819d7ade91c0428356a1f6 (patch)
tree2c4ea63afd30395872f987901149fdc3031aae41
parentfbbb18659ca0fe54592500b28665c3d960ba287a (diff)
[fix] Horizontal scroll
-rw-r--r--xmouseless.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xmouseless.c b/xmouseless.c
index b5ce68a..75d2aea 100644
--- a/xmouseless.c
+++ b/xmouseless.c
@@ -217,7 +217,7 @@ void handle_key(KeyCode keycode, Bool is_press) {
scrollinfo.speed_y += sign * scroll_bindings[i].y;
/* scroll once, workaround for scrolling not working the first time */
- int scroll_x, scroll_y = 0;
+ int scroll_x = 0, scroll_y = 0;
if (scrollinfo.speed_x < 0) scroll_x = -1;
if (scrollinfo.speed_x > 0) scroll_x = 1;
if (scrollinfo.speed_y < 0) scroll_y = -1;