Portal save/file dialog maps centered behind a maximized window and without focus — desktop appears completely frozen
What happened
A download on a web page made Brave open a save dialog through
xdg-desktop-portal-gtk. The dialog mapped centered, behind the maximized Brave
window, and without focus. Brave was blocked waiting for the portal's D-Bus reply,
so its window stopped repainting and ignored input.
The result is indistinguishable from a full desktop freeze: the browser covers the screen, does not redraw, and swallows every click and keystroke, while the dialog that would release it is invisible underneath. The only window on screen is the dead one.
Nothing was actually wrong with the compositor — Hyprland and the Omarchy shell were
both running and painting the whole time, which is how I eventually reached a terminal
and found the dialog with hyprctl clients.
Evidence
The dialog, from hyprctl clients -j:
class: xdg-desktop-portal-gtk
title: storeeu.example.com wants to save
pid: 1611
at: [363, 213] size: [875, 600]
floating: True mapped: True
focusHistoryID: 2
The window covering it:
class: brave-browser
at: [2, 58] size: [1596, 940]
floating: True fullscreen: 1 (maximized)
focusHistoryID: 0 (focused)
Logical output area is 1600x1000 (eDP-1, 2560x1600 @ 120 Hz, scaled). So the dialog was centered exactly where the maximized window sits, and the requester — not the dialog — held focus.
Brave itself was not hung at the OS level: all threads in normal waits, main process
at ~3% of a core, GPU process idle because nothing was asking for frames. Kernel log
clean, no DRM/xe errors. 8 GiB of 15 free, swap at 0, memory and IO pressure zero.
Where Omarchy comes in
default/hypr/apps/system.lua:16 puts every portal window into the floating treatment:
-- The portal only ever shows dialogs — file pickers, screen shares, permission
-- prompts — so every one of its windows belongs in the floating treatment,
-- whatever the app that asked for it titled it.
o.window("xdg-desktop-portal-gtk", { tag = "+floating-window" })
and the tag (lines 2-4) gives float = true, center = true, size = { 875, 600 }.
The rule works exactly as written — the dialog was floating, centered, 875x600. What it does not express is that a dialog which blocks its requester must also land above that requester and take focus. Centering is what puts it under a maximized window rather than beside it, so the rule makes the invisible case the likely one.
What I verified does work
The generic path is fine, so this is not simply "new windows don't get focus":
- Floating window maximized (
fullscreen_state internal = 1), focused. - Mapped a second window that matches the same
floating-windowtag. - The new window took focus (
focusHistoryID: 0) and the maximized window dropped out of its maximized state on its own.
So a plain new window behaves correctly under a maximized window. Something about this path does not.
Two candidates, not yet separated
- The requester takes focus back.
default/hypr/looknfeel.lua:111setsfocus_on_activate = true. If Brave requests activation after the portal dialog maps, it would pull focus back and leave the dialog behind it. There is precedent for exactly this shape of bug in the tree —default/hypr/apps/telegram.lua:2carves outfocus_on_activate = falsefor Telegram. - The dialog never asks for focus.
xdg-desktop-portal-gtkwas already running (PID 1611, up over a day) and the dialog is a new toplevel of that existing client. If it maps without an activation token, Hyprland has no reason to raise it, and because the portal is a separate process there is no transient-parent relationship to the Brave surface to inherit stacking from.
misc:on_focus_under_fullscreen = 1 (take_over, set at looknfeel.lua:113) does not
cover this either way: its description scopes it to tiled windows asking for focus
under a fullscreen or maximized window, and Omarchy's own rule makes portal dialogs
floating.
Suggested direction
Alongside the existing rule in apps/system.lua, something that keeps a blocking
dialog in front of whatever asked for it:
o.window("xdg-desktop-portal-gtk", { stay_focused = true })
stay_focused is already used in the tree (apps/davinci-resolve.lua:11, with
false). I have not tested this — a z-order rule may be the better answer than a focus
rule, and whichever is chosen should be checked against the screen-share and
permission prompts the same class serves, not just file pickers.
Reproducing
- Maximize a Chromium-based browser window (Omarchy's
fullscreen: 1state). - From a page, trigger a download that goes through the portal's Save dialog.
- The dialog appears centered under the browser window, unfocused; the browser is modal-blocked and looks frozen.
I could not re-trigger it on demand after the fact — reproducing it means starting a real download, so the single occurrence above is what I have, forensics and all. No screen capture: by the time the cause was identified the dialog had been answered.
ALT + TAB reaches the dialog once you know it is there. kill <portal-gtk pid> also
releases the browser, with the portal restarting on demand.
System
- Omarchy 4.5.0-3
- Hyprland 0.56.2
- Kernel 7.2.15-1-omarchy, Arch x86_64, SDDM, Wayland
- Intel Core 5 320 (Wildcat Lake) / Intel Graphics (Xe3), driver
xe - eDP-1 2560x1600 @ 120 Hz, logical 1600x1000
- brave-bin 1:1.99.55-1, xdg-desktop-portal 1.22.1-2, xdg-desktop-portal-gtk 1.15.3-2, xdg-desktop-portal-hyprland 1.4.1-2
Full omarchy-debug output available on request. Note in passing: the documented
omarchy debug route does not exist in 4.5.0-3 (Unknown Omarchy command) — the
omarchy-debug binary still works.
Summary: I hit this on Omarchy 4.5.0-3 as well. xdg-desktop-portal-gtk cannot attach the Wayland parent window from Chromium or Electron, so the Save dialog opens behind the maximized browser. Adding stay_focused = true and pin = true fixes it, and quattro needs the same rule for folio-chooser.
Here are two details from our logs and from quattro:
-
Why the dialog has no parent window: On every Wayland
FileChoosercall from Chrome (158.0.8127.36-1) or Electron,journalctl --user -u xdg-desktop-portal-gtk.servicelogs:xdg-desktop-portal-gtk[...]: Unhandled parent window type xdg-desktop-portal-gtk[...]: Failed to associate portal window with parent windowBecause parent association fails, the dialog maps as a standalone
875x600centered float, and the maximized browser (fullscreen: 1) stays in front with focus. -
folio-chooseronquattrohas the same rule: Indefault/hypr/apps/system.luaonquattro,folio-chooseralso uses onlytag = "+floating-window"(o.window("folio-chooser", { tag = "+floating-window" })), with no focus or z-order rule.
Tested workaround
This rule in ~/.config/hypr/hyprland.lua keeps portal dialogs in front of maximized windows and focused (tested with hyprctl reload and hyprctl configerrors):
o.window("(xdg-desktop-portal-gtk|folio-chooser)", {
stay_focused = true,
pin = true,
})
GPT-6 High in Codex reviewed the report, the follow-up comment, and the current quattro window rules. default/hypr/apps/system.lua still applies the floating-window tag to both xdg-desktop-portal-gtk and folio-chooser. This source check does not establish why the dialog lost focus; no runtime reproduction or workaround was tested in this review.
My classification was bug, but the second classifier returned no answer, so classification remains unsettled. This needs maintainer follow-up before verification can continue. The diagnosis above is from one model only; no second diagnostic review ran.
I could not reproduce the hidden, unfocused dialog on a disposable Omarchy ISO worker running quattro at 465247f11ea3eadd3a2e9338300fb67051cf67ed, Hyprland 0.57.2 and Chromium 158.0.8127.36-2. Folio and GTK Save dialogs opened visibly and took focus. GTK also did so on a tiling workspace while the floating, unpinned browser remained maximized, including a subsequent request through the same portal service. This does not establish that the reported Brave/Hyprland 0.56.2 failure is fixed; no fix has been verified for this issue.
Please confirm whether it still occurs on your currently installed versions, whether Brave was popped with Super+O, and whether the workspace used the floating layout. The exact page action that opened the dialog, and whether you clicked Brave or switched windows before collecting the original state, would also help distinguish initial focus failure from later focus loss.
If it recurs, please collect the full hyprctl clients -j, hyprctl activewindow -j and hyprctl activeworkspace -j output before using Alt+Tab to recover, preferably from a second session so collecting it does not change focus. The omitted pinned, tags and workspace fields matter here. Please also include journalctl --user -b -u xdg-desktop-portal-gtk.service --since '5 minutes ago' --no-pager, systemctl --user show xdg-desktop-portal-gtk.service -p ActiveEnterTimestamp, and the Omarchy, Hyprland and Brave versions then running.
GPT-6 in Codex (effort not exposed) ran these checks. Opus 5.5 High and muse-wonder via pi, thinking high reviewed the report, source and first worker results; neither established a cause or a verified link to the related fixes. Their agreement on that limit does not guarantee independence. This is waiting for reporter evidence.