From 68d4301b9fafca22fc6d8eea71260e7230fc6383 Mon Sep 17 00:00:00 2001 From: lkn Date: Sat, 23 May 2026 13:37:11 +0200 Subject: [PATCH] fix: modal dialogs not receiving mouse clicks on Wayland frame_buf_at() could not find WINGs dialog frame_bufs because they have no tree wrapper (only a bare scene_buf in WL_LAYER_FLOATING). After the walk-up stops at the level_tree bucket, Step 4 only checks fb->tree, missing tree-less frame_bufs entirely. Add Step 5: match tree-less frame_bufs whose scene_buf node is a direct child of a level_tree bucket. This resolves clicks on WINGs modal dialogs (Run dialog, info panels, etc.). --- src/backend/wayland/wl_backend.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/backend/wayland/wl_backend.c b/src/backend/wayland/wl_backend.c index 6b05e96..21c5341 100644 --- a/src/backend/wayland/wl_backend.c +++ b/src/backend/wayland/wl_backend.c @@ -3943,7 +3943,14 @@ frame_buf_at(int px, int py) return fb; } - /* Step 5: topmost node was a client surface — not a WM frame. */ + /* Step 5: match a tree-less frame_buf (WINGs dialog) whose scene_buf + * is a direct child of a level_tree bucket. */ + wl_list_for_each(fb, &wl_state.frame_list, link) { + if (!fb->tree && fb->scene_buf && &fb->scene_buf->node == n) + return fb; + } + + /* Step 6: topmost node was a client surface — not a WM frame. */ return NULL; }