From 354e39eefa010cad2c05ccbf80729bb942b9536a Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 26 Jul 2022 16:04:41 +1000 Subject: [PATCH] xwayland: correct the type for the discrete scroll events Not that it actually matters since the typedef is int32_t anyway, but this theoretically avoids an erroneous call to wl_fixed_to_double() on that value. Signed-off-by: Peter Hutterer --- hw/xwayland/xwayland-input.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/xwayland/xwayland-input.c b/hw/xwayland/xwayland-input.c index 784972aed..16b58a2d5 100644 --- a/hw/xwayland/xwayland-input.c +++ b/hw/xwayland/xwayland-input.c @@ -670,8 +670,8 @@ dispatch_scroll_motion(struct xwl_seat *xwl_seat) const int divisor = 10; wl_fixed_t dy = xwl_seat->pending_pointer_event.scroll_dy; wl_fixed_t dx = xwl_seat->pending_pointer_event.scroll_dx; - wl_fixed_t discrete_dy = xwl_seat->pending_pointer_event.scroll_discrete_dy; - wl_fixed_t discrete_dx = xwl_seat->pending_pointer_event.scroll_discrete_dx; + int32_t discrete_dy = xwl_seat->pending_pointer_event.scroll_discrete_dy; + int32_t discrete_dx = xwl_seat->pending_pointer_event.scroll_discrete_dx; valuator_mask_zero(&mask); if (xwl_seat->pending_pointer_event.has_vertical_scroll) -- GitLab