Hopefully insure people using the GUI mode with audiogame-manager do not get stuck because some messages were only appearing in the terminal which may not be present at all in the GUI.
This commit is contained in:
@@ -108,7 +108,10 @@ game_removal() {
|
||||
source .includes/bottle.sh
|
||||
get_bottle "${game[0]}"
|
||||
|
||||
read -rp "This will remove the game files for \"${game[2]}\" from the shared wine bottle. To continue press enter. To cancel press control+c. " continue
|
||||
if ! agm_yesno "Confirm Removal" "Audio Game Removal" "Are you sure you want to remove \"${game[2]}\"?"; then
|
||||
echo "Removal cancelled."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# kill any previous existing wineservers for this prefix in case they didn't shut down properly.
|
||||
wineserver -k
|
||||
@@ -117,10 +120,9 @@ game_removal() {
|
||||
if [[ -n "$winePath" ]]; then
|
||||
local gameDir="$(winepath "$winePath")"
|
||||
if [[ -d "$gameDir" ]]; then
|
||||
echo "Removing game directory: $gameDir"
|
||||
rm -rf "$gameDir"
|
||||
rm -rfv "$gameDir" | agm_progressbox "Removing Game" "Removing \"${game[2]}\" files..."
|
||||
else
|
||||
echo "Game directory not found, skipping file removal."
|
||||
agm_msgbox "Game Removal" "" "Game directory not found, skipping file removal."
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
@@ -368,6 +370,9 @@ else
|
||||
dialogType="yad"
|
||||
fi
|
||||
|
||||
# Source dialog interface early for progress display
|
||||
source .includes/dialog-interface.sh
|
||||
|
||||
# If display isn't set assume we are launching from console and an X environment is running using display :0
|
||||
if [[ -z "$DISPLAY" ]]; then
|
||||
export DISPLAY=":0"
|
||||
@@ -388,8 +393,7 @@ fi
|
||||
# Update the cache for older versions of audiogame-manager
|
||||
if [[ -d "${configFile%/*}/cache" ]]; then
|
||||
{ mv -v "${configFile%/*}/cache/"* "${cache}"
|
||||
rmdir -v "${configFile%/*}/cache/"; } | dialog \
|
||||
--backtitle "Audiogame Manager" --progressbox "Updating cache, please wait..." -1 -1
|
||||
rmdir -v "${configFile%/*}/cache/"; } | agm_progressbox "Audiogame Manager" "Updating cache, please wait..."
|
||||
fi
|
||||
checkWinetricksUpdate="false"
|
||||
# Turn off debug messages
|
||||
@@ -420,7 +424,7 @@ export nvdaControllerClientDll="${ipfsGateway}/ipfs/QmWu7YdSbKMk1Qm5DKvEA5hk1YuA
|
||||
# Source helper functions
|
||||
source .includes/bottle.sh # Also sourced in functions that need it
|
||||
source .includes/desktop.sh
|
||||
source .includes/dialog-interface.sh
|
||||
# dialog-interface.sh already sourced earlier
|
||||
source .includes/functions.sh
|
||||
source .includes/help.sh
|
||||
source .includes/update.sh
|
||||
|
Reference in New Issue
Block a user