From 2a343e24c5123152fe6fb045ec5330253a3cd613 Mon Sep 17 00:00:00 2001 From: Tobias Powalowski Date: Wed, 6 Sep 2023 09:09:26 +0200 Subject: [PATCH] remove cancel-label --- usr/bin/archboot-clock.sh | 2 +- usr/bin/archboot-launcher.sh | 6 +++--- usr/bin/archboot-localize.sh | 4 ++-- usr/bin/archboot-pacsetup.sh | 2 +- usr/lib/archboot/common.sh | 2 +- usr/lib/archboot/installer/base.sh | 10 ---------- 6 files changed, 8 insertions(+), 18 deletions(-) diff --git a/usr/bin/archboot-clock.sh b/usr/bin/archboot-clock.sh index 8438e3451..1f6c441b7 100755 --- a/usr/bin/archboot-clock.sh +++ b/usr/bin/archboot-clock.sh @@ -32,7 +32,7 @@ _timezone () { _ZONES="${_ZONES} ${i} -" done #shellcheck disable=SC2086 - if _dialog --cancel-label "Back" --title " Timezone " --menu "" 21 30 16 ${_ZONES} 2>${_ANSWER}; then + if _dialog --title " Timezone " --menu "" 21 30 16 ${_ZONES} 2>${_ANSWER}; then _SET_ZONE="1" _ZONE=$(cat ${_ANSWER}) [[ "${_ZONE}" == "${_REGION}" ]] || _ZONE="${_REGION}/${_ZONE}" diff --git a/usr/bin/archboot-launcher.sh b/usr/bin/archboot-launcher.sh index 3428a9095..bbf425fbd 100755 --- a/usr/bin/archboot-launcher.sh +++ b/usr/bin/archboot-launcher.sh @@ -20,7 +20,7 @@ _check_manage() { } _desktop () { - _dialog --cancel-label "Back" --title " Desktop Menu " --menu "" 10 40 6 "${_DESKTOP[@]}" 2>"${_ANSWER}" || return 1 + _dialog --title " Desktop Menu " --menu "" 10 40 6 "${_DESKTOP[@]}" 2>"${_ANSWER}" || return 1 [[ -e /.launcher-running ]] && rm /.launcher-running _EXIT=$(cat "${_ANSWER}") source /etc/locale.conf @@ -51,7 +51,7 @@ _desktop () { } _manage() { - _dialog --cancel-label "Back" --title " Manage Archboot Menu " --menu "" 9 50 5 "${_MANAGE[@]}" 2>"${_ANSWER}" || return 1 + _dialog --title " Manage Archboot Menu " --menu "" 9 50 5 "${_MANAGE[@]}" 2>"${_ANSWER}" || return 1 clear [[ -e /.launcher-running ]] && rm /.launcher-running _EXIT=$(cat "${_ANSWER}") @@ -67,7 +67,7 @@ _manage() { _exit() { #shellcheck disable=SC2086 - _dialog --cancel-label "Back" --title " Exit Menu " --menu "" 9 30 5 \ + _dialog --title " Exit Menu " --menu "" 9 30 5 \ "1" "Exit Program" \ "2" "Reboot System" \ "3" "Poweroff System" 2>${_ANSWER} || return 1 diff --git a/usr/bin/archboot-localize.sh b/usr/bin/archboot-localize.sh index 3bb40bd38..acc451fe6 100755 --- a/usr/bin/archboot-localize.sh +++ b/usr/bin/archboot-localize.sh @@ -16,7 +16,7 @@ _locale_menu() { _LOCALE=$(cat "${_ANSWER}") if [[ "${_LOCALE}" == "OTHER" ]]; then #shellcheck disable=SC2086 - if _dialog --cancel-label "Back" --title " Other Locale " --menu "" 17 35 11 ${_OTHER_LOCALES} 2>${_ANSWER}; then + if _dialog --title " Other Locale " --menu "" 17 35 11 ${_OTHER_LOCALES} 2>${_ANSWER}; then _LOCALE=$(cat ${_ANSWER}) else _LOCALE="" @@ -41,7 +41,7 @@ _vconsole_keymap() { _KEYMAPS="${_KEYMAPS} ${i} -" done #shellcheck disable=SC2086 - if _dialog --cancel-label "Back" --title " Keymap Layout " --menu "" 13 40 7 ${_KEYMAPS} 2>${_ANSWER}; then + if _dialog --title " Keymap Layout " --menu "" 13 40 7 ${_KEYMAPS} 2>${_ANSWER}; then #shellcheck disable=SC2086 _KEYMAP=$(cat ${_ANSWER}) else diff --git a/usr/bin/archboot-pacsetup.sh b/usr/bin/archboot-pacsetup.sh index 8a2fb0f8e..e31a03cf7 100755 --- a/usr/bin/archboot-pacsetup.sh +++ b/usr/bin/archboot-pacsetup.sh @@ -39,7 +39,7 @@ _select_mirror() { #shellcheck disable=SC2155 local _SERVER=$(cat "${_ANSWER}") if [[ "${_SERVER}" == "Custom Mirror" ]]; then - _dialog --cancel-label "Back" --inputbox "Enter the full URL to repositories." 8 65 \ + _dialog --inputbox "Enter the full URL to repositories." 8 65 \ "" 2>"${_ANSWER}" || _SYNC_URL="" _SYNC_URL=$(cat "${_ANSWER}") else diff --git a/usr/lib/archboot/common.sh b/usr/lib/archboot/common.sh index e1557589f..5956e35aa 100644 --- a/usr/lib/archboot/common.sh +++ b/usr/lib/archboot/common.sh @@ -79,7 +79,7 @@ _riscv64_check() { # returns: whatever dialog did _dialog() { - dialog --backtitle "${_TITLE}" --aspect 15 "$@" + dialog --cancel-label "Back" --backtitle "${_TITLE}" --aspect 15 "$@" return $? } diff --git a/usr/lib/archboot/installer/base.sh b/usr/lib/archboot/installer/base.sh index 6a8918128..e2c378b48 100644 --- a/usr/lib/archboot/installer/base.sh +++ b/usr/lib/archboot/installer/base.sh @@ -26,16 +26,6 @@ _set_title() { fi } -# _dialog() -# an el-cheapo dialog wrapper -# -# parameters: see dialog(1) -# returns: whatever dialog did -_dialog() { - dialog --cancel-label "Back" --backtitle "${_TITLE}" --aspect 15 "$@" - return $? -} - _printk() { case ${1} in