diff --git a/src/wayland/meta-wayland-seat.c b/src/wayland/meta-wayland-seat.c index ea4d4608c..7b225a660 100644 --- a/src/wayland/meta-wayland-seat.c +++ b/src/wayland/meta-wayland-seat.c @@ -720,3 +720,12 @@ meta_wayland_seat_get_current_surface (MetaWaylandSeat *seat, return NULL; } + +struct wl_client * +meta_wayland_seat_get_input_focus_client (MetaWaylandSeat *seat) +{ + if (seat->input_focus) + return wl_resource_get_client (seat->input_focus->resource); + else + return NULL; +} diff --git a/src/wayland/meta-wayland-seat.h b/src/wayland/meta-wayland-seat.h index 83fd7de1e..169a92e4e 100644 --- a/src/wayland/meta-wayland-seat.h +++ b/src/wayland/meta-wayland-seat.h @@ -98,3 +98,5 @@ MetaWaylandInput * meta_wayland_seat_get_input (MetaWaylandSeat *seat); MetaWaylandSurface * meta_wayland_seat_get_current_surface (MetaWaylandSeat *seat, ClutterInputDevice *device, ClutterEventSequence *sequence); + +struct wl_client * meta_wayland_seat_get_input_focus_client (MetaWaylandSeat *seat);