From d3ebf99b0fcadff6b70e6d7e90b956330cefe8a1 Mon Sep 17 00:00:00 2001 From: Tony Crisci Date: Fri, 6 Oct 2017 06:54:43 -0400 Subject: xdg-popup: basic pointer grab --- include/wlr/types/wlr_xdg_shell_v6.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'include') diff --git a/include/wlr/types/wlr_xdg_shell_v6.h b/include/wlr/types/wlr_xdg_shell_v6.h index b7acc2c4..408df16a 100644 --- a/include/wlr/types/wlr_xdg_shell_v6.h +++ b/include/wlr/types/wlr_xdg_shell_v6.h @@ -2,11 +2,13 @@ #define WLR_TYPES_WLR_XDG_SHELL_V6_H #include +#include #include struct wlr_xdg_shell_v6 { struct wl_global *wl_global; struct wl_list clients; + struct wl_list popup_grabs; uint32_t ping_timeout; struct { @@ -36,6 +38,18 @@ struct wlr_xdg_popup_v6 { struct wlr_xdg_surface_v6 *parent; struct wlr_seat *seat; struct wlr_box geometry; + + struct wl_list grab_link; // wlr_xdg_popup_grab_v6::popups +}; + +// each seat gets a popup grab +struct wlr_xdg_popup_grab_v6 { + struct wl_client *client; + struct wlr_seat_pointer_grab pointer_grab; + struct wlr_seat *seat; + struct wl_list popups; + struct wl_list link; // wlr_xdg_shell_v6::popup_grabs + // TODO: seat_handle destroy will release the grab }; enum wlr_xdg_surface_v6_role { -- cgit v1.2.3