From 86ceded2417c7bd52122f7d9f9d5fbf7089b475f Mon Sep 17 00:00:00 2001 From: Esme Povirk Date: Wed, 13 Mar 2024 19:20:28 +0000 Subject: [PATCH] main.gudl: Work around Skyrim Launcher focus bug on Wine. --- xalia/main.gudl | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/xalia/main.gudl b/xalia/main.gudl index b69890e..cc9e091 100644 --- a/xalia/main.gudl +++ b/xalia/main.gudl @@ -246,6 +246,19 @@ image (interactable and parent.(dialog and win32_process_name == "SkyrimLauncher } } +dialog (win32_process_name == "SkyrimLauncher" and name == "Skyrim") { + if (parent.child_matches(win32_process_name == "SkyrimLauncher" and name == "Skyrim Options" and visible) and active) { + // work around focus sometimes incorrectly reverting to main window on Wine when a sub-subwindow closes + interactable: false; + } +} +dialog (win32_process_name == "SkyrimLauncher" and name == "Skyrim Options" and visible) { + if (parent.child_matches(win32_process_name == "SkyrimLauncher" and name == "Skyrim" and active)) { + // work around focus sometimes incorrectly reverting to main window on Wine when a sub-subwindow closes + interactable: true; + } +} + // APPLICATION: VLC layered_pane (spi_application.name == "vlc") { // Buttons along the top of preferences window are checkboxes that do not update the UI on Toggle