aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonan Pigott <rpigott@berkeley.edu>2020-07-26 20:21:53 -0700
committerSimon Ser <contact@emersion.fr>2020-07-27 10:39:41 +0200
commit39fd2335bf47ca33e28f61ec7a194c15a9ecc61e (patch)
treeb2fb3be68db6560a4ab6e188e2d009332342abbe
parentc72efcd1ce070dc5a55625de1b0ef2c6630ce8dc (diff)
virtual_pointer: remember current axis for axis events
-rw-r--r--types/wlr_virtual_pointer_v1.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/types/wlr_virtual_pointer_v1.c b/types/wlr_virtual_pointer_v1.c
index aed3647b..75238447 100644
--- a/types/wlr_virtual_pointer_v1.c
+++ b/types/wlr_virtual_pointer_v1.c
@@ -103,7 +103,8 @@ static void virtual_pointer_axis(struct wl_client *client,
return;
}
struct wlr_input_device *wlr_dev = &pointer->input_device;
- pointer->axis_valid[axis] = true;
+ pointer->axis = axis;
+ pointer->axis_valid[pointer->axis] = true;
pointer->axis_event[pointer->axis].device = wlr_dev;
pointer->axis_event[pointer->axis].time_msec = time;
pointer->axis_event[pointer->axis].orientation = axis;