fix: backport upstream gamescope fix for games left behind Steam's loading screen (#401)

This commit is contained in:
Kurt Himebauch authored and GitHub committed 2026-10-07 15:28:11 -04:00
1 parent 4454a6d39a
commit 9310d19857
4 files changed
+132 -2

No files matched your search

+6
View File
@@ -38,6 +38,12 @@ library list, before anything is published.
iconify request is remembered and the window goes back to NormalState before input returns to it,
then focus is handed over again. `GAMESCOPE_RESTORE_FOCUS_WINDOW` on the root window asks for the
same restore from outside (the session script's resume watcher).
- `0114-take-override-redirect-from-mapnotify.patch` - upstream (ValveSoftware/gamescope 3829340),
verbatim; drop it once the runtime's gamescope includes it. Wine creates a game's window
override-redirect and makes it managed before mapping it, which sends no X event. When gamescope
read the window's attributes first, it kept the window as override-redirect and left it out of
`GAMESCOPE_FOCUSABLE_WINDOWS`, so the client kept its loading screen over the running game
(Skyrim SE, A Plague Tale: Innocence, on the games' own Xwayland). MapNotify now refreshes the flag.
Sixteen more of Armada's patches are DRM/lease/HDR-on-KMS work for a native display, which this
app's Wayland-hosted gamescope never reaches, or need a newer gamescope than the runtime has.
@@ -0,0 +1,35 @@
From: Matthew Schwartz <matthew.schwartz@linux.dev>
Subject: [PATCH] steamcompmgr: take override-redirect from MapNotify
Wine creates a toplevel as override-redirect and flips it to managed with
XChangeWindowAttributes while it is unmapped, which generates no X event.
When add_win reads the attributes before the flip, the window stays cached
as override-redirect and is left out of GAMESCOPE_FOCUSABLE_APPS. Steam
then keeps its loading screen over the game, as with A Plague Tale:
Innocence (752590). Before 2238420d, the focus nudge's move usually
refreshed the flag.
MapNotify carries the current override-redirect state, so refresh the
cached flag there rather than re-reading the attributes.
Closes: #2457
---
src/steamcompmgr.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/steamcompmgr.cpp b/src/steamcompmgr.cpp
index f00b62c..cb3b9c6 100644
--- a/src/steamcompmgr.cpp
+++ b/src/steamcompmgr.cpp
@@ -8778,7 +8778,11 @@ void xwayland_ctx_t::Dispatch()
steamcompmgr_win_t * w = find_win(ctx, ev.xmap.window);
if (w && w->xwayland().id == ev.xmap.window)
+ {
+ // Wine flips override-redirect while unmapped and the flip itself sends no event.
+ w->xwayland().a.override_redirect = ev.xmap.override_redirect;
map_win(ctx, ev.xmap.window, ev.xmap.serial);
+ }
break;
}
case UnmapNotify:
+2 -2
View File
@@ -1,3 +1,3 @@
GAMESCOPE_REPO=Droid-Deck/DroidDeck-Components
GAMESCOPE_TAG=gamescope-3.16.29-p8
GAMESCOPE_SHA256=65fcc17af1aee4944a42ce1e688db61ceb10db5f299f0de75e338f56646e2953
GAMESCOPE_TAG=gamescope-3.16.29-p9
GAMESCOPE_SHA256=7123a37bdbcd0d76d4bd1d7490e5d2017221e036395fdd48c1e92458594ca769