diff options
author | Olivier Blin <oblin@mandriva.org> | 2005-08-28 17:51:03 +0000 |
---|---|---|
committer | Olivier Blin <oblin@mandriva.org> | 2005-08-28 17:51:03 +0000 |
commit | 0e3c0c921f9b36993819c05082e780add85e5f8d (patch) | |
tree | a873c88b33aa844ce107e5bb604bece905d4634f /perl-install/network | |
parent | 605c6b07c0afebfc6c0f1beca43b1081fbf0ad0d (diff) | |
download | drakx-backup-do-not-use-0e3c0c921f9b36993819c05082e780add85e5f8d.tar drakx-backup-do-not-use-0e3c0c921f9b36993819c05082e780add85e5f8d.tar.gz drakx-backup-do-not-use-0e3c0c921f9b36993819c05082e780add85e5f8d.tar.bz2 drakx-backup-do-not-use-0e3c0c921f9b36993819c05082e780add85e5f8d.tar.xz drakx-backup-do-not-use-0e3c0c921f9b36993819c05082e780add85e5f8d.zip |
move %wireless_enc_modes in network::wireless
Diffstat (limited to 'perl-install/network')
-rw-r--r-- | perl-install/network/netconnect.pm | 12 | ||||
-rw-r--r-- | perl-install/network/wireless.pm | 7 |
2 files changed, 10 insertions, 9 deletions
diff --git a/perl-install/network/netconnect.pm b/perl-install/network/netconnect.pm index bfd40c730..331568ab3 100644 --- a/perl-install/network/netconnect.pm +++ b/perl-install/network/netconnect.pm @@ -146,13 +146,6 @@ sub real_main { 4 => N("PAP/CHAP"), ); - my %wireless_enc_modes = ( - none => N("None"), - open => N("Open WEP"), - restricted => N("Restricted WEP"), - 'wpa-psk' => N("WPA Pre-Shared Key"), - ); - my $offer_to_connect = sub { if ($net->{type} eq 'adsl' && !member($net->{adsl}{method}, qw(static dhcp)) || member($net->{type}, qw(modem isdn isdn_external))) { @@ -1017,8 +1010,9 @@ notation (for example, 1.2.3.4).")), disabled => sub { $wireless_roaming } }, { label => N("Network name (ESSID)"), val => \$ethntf->{WIRELESS_ESSID} }, { label => N("Encryption mode"), val => \$wireless_enc_mode, - list => [ sort { $wireless_enc_modes{$a} cmp $wireless_enc_modes{$b} } keys %wireless_enc_modes ], - format => sub { $wireless_enc_modes{$_[0]} } }, + list => [ keys %network::wireless::wireless_enc_modes ], + sort => 1, + format => sub { translate($network::wireless::wireless_enc_modes{$_[0]}) } }, { label => N("Encryption key"), val => \$wireless_enc_key, disabled => sub { $wireless_enc_mode eq 'none' } }, { text => N("Allow access point roaming"), val => \$wireless_roaming, type => "bool" }, { label => N("Network ID"), val => \$ethntf->{WIRELESS_NWID}, advanced => 1 }, diff --git a/perl-install/network/wireless.pm b/perl-install/network/wireless.pm index 782b24131..62971bcaf 100644 --- a/perl-install/network/wireless.pm +++ b/perl-install/network/wireless.pm @@ -3,6 +3,13 @@ package network::wireless; use strict; use common; +our %wireless_enc_modes = ( + none => N("None"), + open => N("Open WEP"), + restricted => N("Restricted WEP"), + 'wpa-psk' => N("WPA Pre-Shared Key"), +); + my $wpa_supplicant_conf = "/etc/wpa_supplicant.conf"; sub convert_wep_key_for_iwconfig { |