diff options
author | Carlos Garnacho <carlosg@gnome.org> | 2020-07-13 14:09:44 +0200 |
---|---|---|
committer | Marge Bot <marge-bot@gnome.org> | 2020-11-27 15:14:33 +0000 |
commit | 00cbcb7ba1d40f415711890fa0cb1dce5f752581 (patch) | |
tree | 6e4654c32970ac27ea5b26525ea7fe10972e49b8 /src/wayland/meta-wayland-tablet-manager.c | |
parent | a8e293522517fad1b1b9ef0139fe120f6675b8f3 (diff) | |
download | mutter-00cbcb7ba1d40f415711890fa0cb1dce5f752581.tar.gz |
core: Centralize cursor renderer and tracker updates
These use now more of a "pull" model, where they receive update
notifications and the relevant input position is queried, instead
of the coordinates being passed along.
This allows to treat cursor renderers all the same independently
of the device they track. This notifying of position changes should
ideally be more backend-y than core-y, a better location will be
figured out in future commits.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1403>
Diffstat (limited to 'src/wayland/meta-wayland-tablet-manager.c')
-rw-r--r-- | src/wayland/meta-wayland-tablet-manager.c | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/src/wayland/meta-wayland-tablet-manager.c b/src/wayland/meta-wayland-tablet-manager.c index 38cec064e..9c81d5afc 100644 --- a/src/wayland/meta-wayland-tablet-manager.c +++ b/src/wayland/meta-wayland-tablet-manager.c @@ -242,30 +242,3 @@ meta_wayland_tablet_manager_ensure_seat (MetaWaylandTabletManager *manager, return tablet_seat; } - -void -meta_wayland_tablet_manager_update_cursor_position (MetaWaylandTabletManager *manager, - const ClutterEvent *event) -{ - MetaWaylandTabletSeat *tablet_seat = NULL; - MetaWaylandTabletTool *tool = NULL; - ClutterInputDeviceTool *device_tool; - ClutterInputDevice *device; - - device = clutter_event_get_source_device (event); - device_tool = clutter_event_get_device_tool (event); - - if (device) - tablet_seat = meta_wayland_tablet_manager_lookup_seat (manager, device); - - if (tablet_seat && device_tool) - tool = meta_wayland_tablet_seat_lookup_tool (tablet_seat, device_tool); - - if (tool) - { - gfloat new_x, new_y; - - clutter_event_get_coords (event, &new_x, &new_y); - meta_wayland_tablet_tool_set_cursor_position (tool, new_x, new_y); - } -} |