list of app names
This commit is contained in:
parent
a62d7fdd99
commit
007c45c5a3
|
@ -1894,7 +1894,7 @@ function menu_wifi {
|
||||||
function menu_app_settings {
|
function menu_app_settings {
|
||||||
detect_installable_apps
|
detect_installable_apps
|
||||||
|
|
||||||
applist=""
|
W=()
|
||||||
appnames=()
|
appnames=()
|
||||||
n=1
|
n=1
|
||||||
app_index=0
|
app_index=0
|
||||||
|
@ -1903,7 +1903,7 @@ function menu_app_settings {
|
||||||
do
|
do
|
||||||
if [[ ${APPS_INSTALLED[$app_index]} != "0" ]]; then
|
if [[ ${APPS_INSTALLED[$app_index]} != "0" ]]; then
|
||||||
if [[ $(function_exists "configure_interactive_${a}") == "1" ]]; then
|
if [[ $(function_exists "configure_interactive_${a}") == "1" ]]; then
|
||||||
applist="$applist $n $a off"
|
W+=("$n" "$a")
|
||||||
n=$((n+1))
|
n=$((n+1))
|
||||||
appnames+=("$a")
|
appnames+=("$a")
|
||||||
fi
|
fi
|
||||||
|
@ -1913,23 +1913,18 @@ function menu_app_settings {
|
||||||
if [ $n -le 1 ]; then
|
if [ $n -le 1 ]; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
backstr=$'Exit'
|
|
||||||
applist="$applist $n $backstr on"
|
|
||||||
appnames+=("Exit")
|
|
||||||
|
|
||||||
# shellcheck disable=SC2086
|
# shellcheck disable=SC2086
|
||||||
choice=$(dialog --stdout --backtitle $"Freedombone" \
|
choice=$(dialog --stdout --backtitle $"Freedombone" \
|
||||||
--title $"Change settings for an App" \
|
--title $"Change settings for an App" \
|
||||||
--menu $'Choose:' \
|
--menu $'Choose:' \
|
||||||
26 40 30 $applist 3>&2 2>&1 1>&3)
|
26 40 30 "${W[@]}" 3>&2 2>&1 1>&3)
|
||||||
|
|
||||||
# shellcheck disable=SC2181
|
# shellcheck disable=SC2181
|
||||||
if [ "$choice" ]; then
|
if [ "$choice" ]; then
|
||||||
app_index=$((choice-1))
|
app_index=$((choice-1))
|
||||||
chosen_app=${appnames[$app_index]}
|
chosen_app=${appnames[$app_index]}
|
||||||
if [[ $chosen_app != "Exit" ]]; then
|
"configure_interactive_${chosen_app}"
|
||||||
"configure_interactive_${chosen_app}"
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue