FINIT: fixed quit button

This commit is contained in:
XargonWan 2025-01-20 14:31:25 +09:00
parent b145d81e1e
commit 33e44568ac
2 changed files with 7 additions and 3 deletions

View file

@ -57,7 +57,7 @@ configurator_destination_choice_dialog() {
# This dialog is for making things easy for new users to move files to common locations. Gives the options for "Internal", "SD Card" and "Custom" locations.
# USAGE: $(configurator_destination_choice_dialog "folder being moved" "action text")
# This function returns one of the values: "Back" "Internal Storage" "SD Card" "Custom Location"
choice=$(rd_zenity --title "RetroDECK Configurator Utility - Moving $1 folder" --info --no-wrap --ok-label="Back" --extra-button="Internal Storage" --extra-button="SD Card" --extra-button="Custom Location" \
choice=$(rd_zenity --title "RetroDECK Configurator Utility - Moving $1 folder" --info --no-wrap --ok-label="Quit" --extra-button="Internal Storage" --extra-button="SD Card" --extra-button="Custom Location" \
--window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
--text="$2")

View file

@ -400,11 +400,15 @@ finit() {
# Internal or SD Card?
local finit_dest_choice=$(configurator_destination_choice_dialog "RetroDECK data" "Welcome to the first setup of RetroDECK.\nPlease carefully read each message prompted during the installation process to avoid any unwanted misconfigurations.\n\nWhere do you want your RetroDECK data folder to be located?\nIn this location a \"retrodeck\" folder will be created.\nThis is the folder that you will use to contain all your important files, such as your own ROMs, BIOSs, Saves and Scraped Data." )
log i "Choice is $finit_dest_choice"
if [[ "$finit_dest_choice" == "" ]]; then
log i "User closed the window"
else
log i "User choice: $finit_dest_choice"
fi
case "$finit_dest_choice" in
"Quit" | "" ) # Back or X button quits
"Quit" | "Back" | "" ) # Back, Quit or X button quits
rm -f "$rd_conf" # Cleanup unfinished retrodeck.cfg if first install is interrupted
log i "Now quitting"
quit_retrodeck