aboutsummaryrefslogtreecommitdiff
path: root/backend/libinput/events.c
diff options
context:
space:
mode:
Diffstat (limited to 'backend/libinput/events.c')
-rw-r--r--backend/libinput/events.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/backend/libinput/events.c b/backend/libinput/events.c
index b9f2f43c..c5d9c67a 100644
--- a/backend/libinput/events.c
+++ b/backend/libinput/events.c
@@ -176,8 +176,25 @@ void handle_libinput_event(struct wlr_libinput_backend *backend,
handle_pointer_button(event, &dev->pointer);
break;
case LIBINPUT_EVENT_POINTER_AXIS:
+#if !LIBINPUT_HAS_SCROLL_VALUE120
+ /* This event must be ignored in favour of the SCROLL_* events */
handle_pointer_axis(event, &dev->pointer);
+#endif
+ break;
+#if LIBINPUT_HAS_SCROLL_VALUE120
+ case LIBINPUT_EVENT_POINTER_SCROLL_WHEEL:
+ handle_pointer_axis_value120(event, &dev->pointer,
+ WLR_AXIS_SOURCE_WHEEL);
+ break;
+ case LIBINPUT_EVENT_POINTER_SCROLL_FINGER:
+ handle_pointer_axis_value120(event, &dev->pointer,
+ WLR_AXIS_SOURCE_FINGER);
break;
+ case LIBINPUT_EVENT_POINTER_SCROLL_CONTINUOUS:
+ handle_pointer_axis_value120(event, &dev->pointer,
+ WLR_AXIS_SOURCE_CONTINUOUS);
+ break;
+#endif
case LIBINPUT_EVENT_TOUCH_DOWN:
handle_touch_down(event, &dev->touch);
break;