From 04aef0164b5bfacdb7d0113bdd7d6fd763246288 Mon Sep 17 00:00:00 2001 From: NelloKudo Date: Sat, 21 Sep 2024 05:03:34 +0200 Subject: [PATCH] More alt-tab refinements for xFCE and WMs --- ...ex11-win32u-HACK-alt-tab-fix-proton.patch} | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) rename patches/wine/0005-osu/{0002-winex11-HACK-xfce-alt-tab-fix-proton.patch => 0002-winex11-win32u-HACK-alt-tab-fix-proton.patch} (75%) diff --git a/patches/wine/0005-osu/0002-winex11-HACK-xfce-alt-tab-fix-proton.patch b/patches/wine/0005-osu/0002-winex11-win32u-HACK-alt-tab-fix-proton.patch similarity index 75% rename from patches/wine/0005-osu/0002-winex11-HACK-xfce-alt-tab-fix-proton.patch rename to patches/wine/0005-osu/0002-winex11-win32u-HACK-alt-tab-fix-proton.patch index a5444b2..855366f 100644 --- a/patches/wine/0005-osu/0002-winex11-HACK-xfce-alt-tab-fix-proton.patch +++ b/patches/wine/0005-osu/0002-winex11-win32u-HACK-alt-tab-fix-proton.patch @@ -1,3 +1,22 @@ +diff --git a/dlls/win32u/window.c b/dlls/win32u/window.c +index 2dcc3e20d3e..4b6b6d40618 100644 +--- a/dlls/win32u/window.c ++++ b/dlls/win32u/window.c +@@ -3427,6 +3427,14 @@ BOOL set_window_pos( WINDOWPOS *winpos, int parent_x, int parent_y ) + + orig_flags = winpos->flags; + ++ /* osu! hack: fix osu! staying over other apps on certain WMs (ex. i3, sway) and xFCE */ ++ if (__wine_get_window_manager() == WINE_WM_UNKNOWN || __wine_get_window_manager() == WINE_WM_X11_XFCE) ++ { ++ if (winpos->hwndInsertAfter == HWND_NOTOPMOST && ++ (get_window_long(winpos->hwnd, GWL_EXSTYLE) & WS_EX_TOPMOST)) ++ winpos->flags |= SWP_NOACTIVATE | SWP_NOZORDER; ++ } ++ + /* First, check z-order arguments. */ + if (!(winpos->flags & SWP_NOZORDER)) + { diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index 98723a302ed..d4211571d9d 100644 --- a/dlls/winex11.drv/window.c