diff --git a/src/compositor.h b/src/compositor.h index 43db92ea8..8a5aa91b5 100644 --- a/src/compositor.h +++ b/src/compositor.h @@ -1158,6 +1158,9 @@ notify_touch(struct weston_seat *seat, uint32_t time, int touch_id, void notify_touch_frame(struct weston_seat *seat); +void +notify_touch_cancel(struct weston_seat *seat); + void weston_layer_entry_insert(struct weston_layer_entry *list, struct weston_layer_entry *entry); diff --git a/src/input.c b/src/input.c index 097c8e739..f5bb54e1c 100644 --- a/src/input.c +++ b/src/input.c @@ -1807,6 +1807,15 @@ notify_touch_frame(struct weston_seat *seat) grab->interface->frame(grab); } +WL_EXPORT void +notify_touch_cancel(struct weston_seat *seat) +{ + struct weston_touch *touch = weston_seat_get_touch(seat); + struct weston_touch_grab *grab = touch->grab; + + grab->interface->cancel(grab); +} + static int pointer_cursor_surface_get_label(struct weston_surface *surface, char *buf, size_t len)