mirror of
https://github.com/brl/mutter.git
synced 2025-06-14 01:09:30 +00:00
backends/native: Move away from ClutterInputDevice coords
Use a new set in MetaInputDeviceNative, this coexists with ClutterInputDevice coords for the time being. This API will eventually be only accessed from the input thread. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
This commit is contained in:

committed by
Marge Bot

parent
cb7794c19c
commit
7d78768809
@ -1495,3 +1495,23 @@ meta_input_device_native_set_mapping_mode (ClutterInputDevice *device,
|
||||
|
||||
device_native->mapping_mode = mapping;
|
||||
}
|
||||
|
||||
void
|
||||
meta_input_device_native_set_coords (MetaInputDeviceNative *device_native,
|
||||
float x,
|
||||
float y)
|
||||
{
|
||||
device_native->pointer_x = x;
|
||||
device_native->pointer_y = y;
|
||||
}
|
||||
|
||||
void
|
||||
meta_input_device_native_get_coords (MetaInputDeviceNative *device_native,
|
||||
float *x,
|
||||
float *y)
|
||||
{
|
||||
if (x)
|
||||
*x = device_native->pointer_x;
|
||||
if (y)
|
||||
*y = device_native->pointer_y;
|
||||
}
|
||||
|
Reference in New Issue
Block a user