diff options
author | dteske <dteske@FreeBSD.org> | 2013-07-05 16:00:01 +0000 |
---|---|---|
committer | dteske <dteske@FreeBSD.org> | 2013-07-05 16:00:01 +0000 |
commit | 0ac55ea171e6d82b0acc861ebcb19fb4db4958c4 (patch) | |
tree | 20324385a5f53dae148a2e6fa863df76ea68f69d /usr.sbin/bsdconfig/networking | |
parent | 1523d4a961431261ec396302c4112265ef2003c7 (diff) | |
download | FreeBSD-src-0ac55ea171e6d82b0acc861ebcb19fb4db4958c4.zip FreeBSD-src-0ac55ea171e6d82b0acc861ebcb19fb4db4958c4.tar.gz |
Use f_show_msg() instead of f_dialog_msgbox() where appropriate. The main
difference between these two functions:
Usage: f_show_msg() $format_string [ $format_args ... ]
Usage: f_dialog_msgbox() $text [ $hline ]
The former lends itself well to displaying the $msg_* i18n text, prompts,
etc. While the latter is better for text you do not control (error strings
captured as a response from external commands) -- or if you have to control
the hline.
Diffstat (limited to 'usr.sbin/bsdconfig/networking')
-rw-r--r-- | usr.sbin/bsdconfig/networking/share/device.subr | 2 | ||||
-rw-r--r-- | usr.sbin/bsdconfig/networking/share/resolv.subr | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/bsdconfig/networking/share/device.subr b/usr.sbin/bsdconfig/networking/share/device.subr index 133bca0..2bb7ba2 100644 --- a/usr.sbin/bsdconfig/networking/share/device.subr +++ b/usr.sbin/bsdconfig/networking/share/device.subr @@ -124,7 +124,7 @@ f_dialog_menu_netdev() done ) if [ ! "$interfaces" ]; then - f_dialog_msgbox "$msg_no_network_interfaces" + f_show_msg "$msg_no_network_interfaces" return $FAILURE fi diff --git a/usr.sbin/bsdconfig/networking/share/resolv.subr b/usr.sbin/bsdconfig/networking/share/resolv.subr index 866f345..01b28af 100644 --- a/usr.sbin/bsdconfig/networking/share/resolv.subr +++ b/usr.sbin/bsdconfig/networking/share/resolv.subr @@ -371,9 +371,9 @@ f_dialog_input_nameserver() local retval=$? case $retval in 1) f_die 1 "$msg_internal_error_nsindex_value" "$nsindex" ;; - 2) f_dialog_msgbox "$msg_resolv_conf_changed_while_editing" + 2) f_show_msg "$msg_resolv_conf_changed_while_editing" return $retval ;; - 3) f_dialog_msgbox "$msg_resolv_conf_entry_no_longer_exists" + 3) f_show_msg "$msg_resolv_conf_entry_no_longer_exists" return $retval ;; esac |