mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 23:50:41 -05:00
backends/native: Translate coordinates of absolute motion events
The motion events of tablets for example need to be mapped on the selected screen area if the input device is configured to use only a part of the active logical monitor. To achieve this behavior each motion event is transformed using the transformation matrix set for the input device. Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/1118
This commit is contained in:
parent
3b2f6ae93d
commit
83553e3f6e
@ -424,6 +424,9 @@ new_absolute_motion_event (MetaSeatNative *seat,
|
||||
meta_xkb_translate_state (event, seat->xkb, seat->button_state);
|
||||
event->motion.x = x;
|
||||
event->motion.y = y;
|
||||
meta_input_device_native_translate_coordinates (input_device, stage,
|
||||
&event->motion.x,
|
||||
&event->motion.y);
|
||||
event->motion.axes = axes;
|
||||
clutter_event_set_device (event, seat->core_pointer);
|
||||
clutter_event_set_source_device (event, input_device);
|
||||
|
Loading…
Reference in New Issue
Block a user