From d4794268267be01e4ef583e1c05bd874adec19e8 Mon Sep 17 00:00:00 2001 From: David Young Date: Fri, 5 Jun 2026 15:51:42 -0600 Subject: [PATCH] bring windows windows forward --- install-windows-apps.sh | 18 ++++++++++++++++-- packages.conf | 1 + 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/install-windows-apps.sh b/install-windows-apps.sh index 91dbd9f..088e06a 100755 --- a/install-windows-apps.sh +++ b/install-windows-apps.sh @@ -121,6 +121,14 @@ download_winlink() { fi } +# Wait for a Wine window to appear and raise it to the front +raise_wine_window() { + for i in $(seq 1 20); do + sleep 1 + xdotool search --class Wine windowfocus windowraise 2>/dev/null && return 0 + done +} + # Install a VARA product using Wine install_vara() { local pattern="$1" @@ -154,7 +162,10 @@ install_vara() { echo "The script will continue once the installer is closed." echo "" - wine "$exe" + wine "$exe" & + local wine_pid=$! + raise_wine_window & + wait "$wine_pid" echo "$exe_name installation complete." } @@ -190,7 +201,10 @@ install_winlink() { echo "The script will continue once the installer is closed." echo "" - wine "$exe" + wine "$exe" & + local wine_pid=$! + raise_wine_window & + wait "$wine_pid" echo "$exe_name installation complete." } diff --git a/packages.conf b/packages.conf index f302a1a..afeaf0c 100644 --- a/packages.conf +++ b/packages.conf @@ -38,6 +38,7 @@ UTILITIES=( wine winetricks xdg-utils + xdotool zim-tools zimwriterfs )