wayland: Let MetaWaylandTabletManager process tablet events

meta_wayland_tablet_manager_update()/handle_event() are called before
the MetaWaylandSeat counterparts. If the event comes from a device
managed by MetaWaylandTabletManager, the event will be exclusively handled
by it.
This commit is contained in:
Carlos Garnacho 2015-01-09 17:29:06 +01:00
parent ec53b5562d
commit c17d85e16b

View File

@ -168,6 +168,9 @@ void
meta_wayland_compositor_update (MetaWaylandCompositor *compositor, meta_wayland_compositor_update (MetaWaylandCompositor *compositor,
const ClutterEvent *event) const ClutterEvent *event)
{ {
if (meta_wayland_tablet_manager_consumes_event (compositor->tablet_manager, event))
meta_wayland_tablet_manager_update (compositor->tablet_manager, event);
else
meta_wayland_seat_update (compositor->seat, event); meta_wayland_seat_update (compositor->seat, event);
} }
@ -197,6 +200,10 @@ gboolean
meta_wayland_compositor_handle_event (MetaWaylandCompositor *compositor, meta_wayland_compositor_handle_event (MetaWaylandCompositor *compositor,
const ClutterEvent *event) const ClutterEvent *event)
{ {
if (meta_wayland_tablet_manager_handle_event (compositor->tablet_manager,
event))
return TRUE;
return meta_wayland_seat_handle_event (compositor->seat, event); return meta_wayland_seat_handle_event (compositor->seat, event);
} }