summaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorSaverio Miroddi <[email protected]>2026-04-28 19:41:11 +0200
committerVictor Kareh <[email protected]>2026-05-27 16:02:51 -0400
commit61a931b17f7694dcd49a0657d8746fbdac3e4e91 (patch)
tree05c46655e89bf6894d497cc8314b55a5f400b701 /src/include
parent220296b67ec2355128a6f98dfc6252d093465c0c (diff)
downloadmarco-61a931b17f7694dcd49a0657d8746fbdac3e4e91.tar.bz2
marco-61a931b17f7694dcd49a0657d8746fbdac3e4e91.tar.xz
window: focus modal dialogs whose ancestor is focused
Fixes #784. Commit 6ea23df ("window: do not unfocus on new window") imported the Metacity bf17c79 / Mutter 998d921d behavior for GNOME Bugzilla #773210: when a new transient maps without taking focus, keep focus on the parent so GTK popup and completion windows and VLC fullscreen controls do not steal keyboard focus. That blanket change also affected modal dialogs whose parent already has focus. Electron and GTK file chooser dialogs can reach meta_window_show() with takes_focus_on_map false because their _NET_WM_USER_TIME is missing or stale. Since 6ea23df, such dialogs are mapped above the parent but keyboard focus stays on the parent, so typing goes to the wrong window. Keep the bf17c79-equivalent behavior for non-modal transients, but when the new window is a META_WINDOW_MODAL_DIALOG whose ancestor is the current focus window, force takes_focus_on_map so the blocking dialog receives keyboard focus immediately.
Diffstat (limited to 'src/include')
0 files changed, 0 insertions, 0 deletions