popup: only close on BUTTON_RELEASE from menuView or when insideMenu active

This commit is contained in:
lkn 2026-06-07 16:00:42 +02:00
parent 1fce95d0cc
commit 8c7b201823
1 changed files with 5 additions and 1 deletions

View File

@ -720,7 +720,11 @@ static void handleActionEvents(WMEvent * event, void *data)
}
bPtr->view->screen->viewBackend->pointer_ungrab(
bPtr->view->screen->viewBackendCtx, event->u.button.time);
if (!bPtr->flags.pullsDown)
/* Only close on release from menu view (drag-select) or insideMenu active.
* A plain click on the button without entering the menu keeps it open. */
if (!bPtr->flags.pullsDown
&& (event->window == bPtr->menuView->window
|| bPtr->flags.insideMenu))
popDownMenu(bPtr);
if (bPtr->timer) {