diff --git a/WINGs/wview.c b/WINGs/wview.c index 1d0f82f..04aa90a 100644 --- a/WINGs/wview.c +++ b/WINGs/wview.c @@ -142,6 +142,7 @@ W_View *W_CreateUnmanagedTopView(W_Screen * screen) return NULL; view->flags.topLevel = 1; + view->flags.popup = 1; return view; } diff --git a/WINGs/wview_wl.c b/WINGs/wview_wl.c index c47c0d7..20e3912 100644 --- a/WINGs/wview_wl.c +++ b/WINGs/wview_wl.c @@ -700,6 +700,18 @@ static void wl_window_realize(void *vctx, W_View *view, const char *name, (void)vctx; (void)view; (void)name; (void)class; (void)owner; } +static void wl_pointer_grab(void *vctx, W_View *view, int owner_events, unsigned long time) +{ + (void)vctx; (void)view; (void)owner_events; (void)time; + /* No-op: Wayland uses implicit grab on button press; popup menus + * receive events via the pointer focus mechanism. */ +} + +static void wl_pointer_ungrab(void *vctx, unsigned long time) +{ + (void)vctx; (void)time; +} + static void wl_window_set_geometry(void *vctx, W_View *view) { (void)vctx; @@ -747,8 +759,8 @@ const W_ViewBackend W_ViewBackendWL = { .window_realize = wl_window_realize, .window_set_geometry = wl_window_set_geometry, .window_withdraw = wl_window_withdraw, - .pointer_grab = NULL, - .pointer_ungrab = NULL, + .pointer_grab = wl_pointer_grab, + .pointer_ungrab = wl_pointer_ungrab, .bell = NULL, .balloon_draw = wl_balloon_draw, .text_init = wl_text_init,