wl_backend: fix resizebar click detection
frame_buf_button_at had a size threshold (width>30 || height>30) that skipped resizebar frame_bufs during hit-testing. The resizebar is wide but short (~8px), so it was always skipped. Clicks in the resizebar area fell through to the parent frame, preventing resize. Remove the size threshold. The smallest-area heuristic already ensures buttons (small) are preferred over resizebars (large) when both match.
This commit is contained in:
parent
4b338d11d0
commit
4f70ab6df5
|
|
@ -3991,7 +3991,6 @@ frame_buf_button_at(int px, int py)
|
|||
if (!fb->scene_buf) continue; /* no scene node */
|
||||
/* Buttons are small children of the titlebar with enabled scene_bufs.
|
||||
* Skip large nodes (titlebars, resizebars) by size threshold. */
|
||||
if (fb->width > 30 || fb->height > 30) continue;
|
||||
if (px < fb->x || px >= fb->x + fb->width) continue;
|
||||
if (py < fb->y || py >= fb->y + fb->height) continue;
|
||||
/* Prefer the smallest (most specific) enclosing fb. */
|
||||
|
|
|
|||
Loading…
Reference in New Issue