STEPS TO REPRODUCE 1. Open gtk4-demo 2. Click on the hamburger button to open a popover 3. Hit Meta to open kicker 4. Type something OBSERVED RESULT The input field of Kicker is not focused. On typing Kicker closes. EXPECTED RESULT Gtk4 popovers are treated like context menus and close on hitting Meta to open kicker. SOFTWARE/OS VERSIONS Operating System: Fedora Linux 41 KDE Plasma Version: 6.2.4 KDE Frameworks Version: 6.8.0 Qt Version: 6.8.0 Kernel Version: 6.11.8-300.fc41.x86_64 (64-bit) Graphics Platform: Wayland Gtk: 4.16.4
It seems we don't dismiss the popup on Qt either, we just send a keyboard_leave which it handles differently.
I've noticed that the Gtk4 popover also stays above kicker: 1) Create a panel on the top or left edge 2) Make kicker wide enough so that it covers the gtk4-demo app 3) Open the popover in the gtk4-demo 4) Hit Meta to open kicker
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kwin/-/merge_requests/6963
For reproducing, instead of opening kicker, you can also use Alt+Tab. I've found another case, where the gtk4 popover doesn't close even on clicking somewhere after tabbing to another window. Would you like to have a reproducer for this as well or do you think this case is also covered already?
Git commit 43f7621eb1ef22704c4c12c21c29945bffa37e47 by David Edmundson. Committed on 09/07/2025 at 09:17. Pushed by davidedmundson into branch 'master'. wayland: close popups upon window activation Popups should grab all input on Wayland, however there are numerous (deliberate) ways to get outside the grab, such as a shortcut that opens a new window or pressing alt-tab. If a popup is active when the focus changes we are left in a state where the new window visibly has focus and appears on top of the popup's main window, but the popup is still visible with an input grab. This is a broken state. This patch cancels popups if the focus window changes for whatever reason. Cancelling a popup also destroys the window server side rather than waiting for the client to handle the popupDone so there is no racey aspect for the next input. M +45 -0 autotests/integration/xdgshellwindow_test.cpp M +7 -0 src/popup_input_filter.cpp M +1 -1 src/popup_input_filter.h https://invent.kde.org/plasma/kwin/-/commit/43f7621eb1ef22704c4c12c21c29945bffa37e47
Git commit 51c0880f47ecd2e29ceb61e9dd9b30a535d18ff8 by Vlad Zahorodnii. Committed on 09/07/2025 at 13:28. Pushed by vladz into branch 'Plasma/6.4'. wayland: close popups upon window activation Popups should grab all input on Wayland, however there are numerous (deliberate) ways to get outside the grab, such as a shortcut that opens a new window or pressing alt-tab. If a popup is active when the focus changes we are left in a state where the new window visibly has focus and appears on top of the popup's main window, but the popup is still visible with an input grab. This is a broken state. This patch cancels popups if the focus window changes for whatever reason. Cancelling a popup also destroys the window server side rather than waiting for the client to handle the popupDone so there is no racey aspect for the next input. (cherry picked from commit 43f7621eb1ef22704c4c12c21c29945bffa37e47) Co-authored-by: David Edmundson <kde@davidedmundson.co.uk> M +45 -0 autotests/integration/xdgshellwindow_test.cpp M +7 -0 src/popup_input_filter.cpp M +1 -1 src/popup_input_filter.h https://invent.kde.org/plasma/kwin/-/commit/51c0880f47ecd2e29ceb61e9dd9b30a535d18ff8