Move keyboard focus to grabbing popup immediately

It seems that QMenu expects to receive keyboard focus when it's mapped,
otherwise keyboard input breaks when using pointer input. In either case,
kwin should move keyboard focus immediately rather than do it on demand.

BUG: 465385
wilder/Plasma/6.3
Vlad Zahorodnii 1 year ago
parent 8955ff5aaa
commit 19c467147a
  1. 2
      src/popup_input_filter.cpp

@ -34,6 +34,8 @@ void PopupInputFilter::handleWindowAdded(Window *window)
if (window->hasPopupGrab()) {
// TODO: verify that the Window is allowed as a popup
m_popupWindows << window;
focus(window);
connect(window, &Window::closed, this, [this, window]() {
m_popupWindows.removeOne(window);
// Move focus to the parent popup. If that's the last popup, then move focus back to the parent

Loading…
Cancel
Save