diff --git a/backend/libinput/pointer.c b/backend/libinput/pointer.c index 9b9996780..fc0300d51 100644 --- a/backend/libinput/pointer.c +++ b/backend/libinput/pointer.c @@ -187,6 +187,8 @@ void handle_pointer_swipe_update(struct libinput_event *event, .fingers = libinput_event_gesture_get_finger_count(gevent), .dx = libinput_event_gesture_get_dx(gevent), .dy = libinput_event_gesture_get_dy(gevent), + .unaccel_dx = libinput_event_gesture_get_dx_unaccelerated(gevent), + .unaccel_dy = libinput_event_gesture_get_dy_unaccelerated(gevent), }; wl_signal_emit_mutable(&pointer->events.swipe_update, &wlr_event); } @@ -228,6 +230,8 @@ void handle_pointer_pinch_update(struct libinput_event *event, .fingers = libinput_event_gesture_get_finger_count(gevent), .dx = libinput_event_gesture_get_dx(gevent), .dy = libinput_event_gesture_get_dy(gevent), + .unaccel_dx = libinput_event_gesture_get_dx_unaccelerated(gevent), + .unaccel_dy = libinput_event_gesture_get_dy_unaccelerated(gevent), .scale = libinput_event_gesture_get_scale(gevent), .rotation = libinput_event_gesture_get_angle_delta(gevent), }; diff --git a/include/wlr/types/wlr_pointer.h b/include/wlr/types/wlr_pointer.h index 756ffa1f6..abc670a8c 100644 --- a/include/wlr/types/wlr_pointer.h +++ b/include/wlr/types/wlr_pointer.h @@ -96,6 +96,7 @@ struct wlr_pointer_swipe_update_event { // Relative coordinates of the logical center of the gesture // compared to the previous event. double dx, dy; + double unaccel_dx, unaccel_dy; }; struct wlr_pointer_swipe_end_event { @@ -117,6 +118,7 @@ struct wlr_pointer_pinch_update_event { // Relative coordinates of the logical center of the gesture // compared to the previous event. double dx, dy; + double unaccel_dx, unaccel_dy; // Absolute scale compared to the begin event double scale; // Relative angle in degrees clockwise compared to the previous event.