aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/bsdinstall/scripts
diff options
context:
space:
mode:
authorDevin Teske <dteske@FreeBSD.org>2016-12-13 02:22:21 +0000
committerDevin Teske <dteske@FreeBSD.org>2016-12-13 02:22:21 +0000
commitd5fddc4dcbe6a33b4203fa7570f846cd1044fa6a (patch)
treee26b5610591e119d5edc66c569fb0b11e359c184 /usr.sbin/bsdinstall/scripts
parent7599c85424bf1c4c8dbe9a1b8b1150871588960b (diff)
Notes
Diffstat (limited to 'usr.sbin/bsdinstall/scripts')
-rwxr-xr-xusr.sbin/bsdinstall/scripts/wlanconfig38
1 files changed, 23 insertions, 15 deletions
diff --git a/usr.sbin/bsdinstall/scripts/wlanconfig b/usr.sbin/bsdinstall/scripts/wlanconfig
index 5093146612dfd..618ce9d910b48 100755
--- a/usr.sbin/bsdinstall/scripts/wlanconfig
+++ b/usr.sbin/bsdinstall/scripts/wlanconfig
@@ -239,14 +239,16 @@ while :; do
fi
f_dialog_title "Network Selection"
- NETWORK=$( sh -c "$DIALOG \
- --title \"$DIALOG_TITLE\" \
- --backtitle \"$DIALOG_BACKTITLE\" \
+ prompt="Select a wireless network to connect to."
+ menu_list=$( echo $NETWORKS | tr '\n' ' ' )
+ NETWORK=$( eval $DIALOG \
+ --title \"\$DIALOG_TITLE\" \
+ --backtitle \"\$DIALOG_BACKTITLE\" \
--extra-button \
--extra-label \"Rescan\" \
- --menu \"Select a wireless network to connect to.\" \
- 0 0 0 \
- $( echo $NETWORKS | tr '\n' ' ' )" \
+ --menu \"\$prompt\" \
+ $height $width $rows \
+ $menu_list \
2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
)
retval=$?
@@ -258,15 +260,21 @@ while :; do
f_dialog_title "Network Selection"
f_yesno "Do you want to select the network manually?" || exit 1
f_dialog_input NETWORK "Enter SSID" || exit 1
- ENCRYPTION=$( $DIALOG \
- --title "$DIALOG_TITLE" \
- --backtitle "$DIALOG_BACKTITLE" \
- --menu "Select encryption type" \
- 0 0 0 \
- "1 WPA/WPA2 PSK" "" \
- "2 WPA/WPA2 EAP" "" \
- "3 WEP" "" \
- "0 None" "" \
+ prompt="Select encryption type"
+ menu_list="
+ '1 WPA/WPA2 PSK' ''
+ '2 WPA/WPA2 EAP' ''
+ '3 WEP' ''
+ '0 None' ''
+ " # END-QUOTE
+ eval f_dialog_menu_size height width rows \"\$DIALOG_TITLE\" \
+ \"\$DIALOG_BACKTITLE\" \"\$prompt\" \"\" $menu_list
+ ENCRYPTION=$( eval $DIALOG \
+ --title \"\$DIALOG_TITLE\" \
+ --backtitle \"\$DIALOG_BACKTITLE\" \
+ --menu \"\$prompt\" \
+ $height $width $rows \
+ $menu_list \
2>&1 >&$DIALOG_TERMINAL_PASSTHRU_FD
) || exit 1
SCANSSID=1