mirror of
https://github.com/gryf/wicd.git
synced 2025-12-20 21:08:06 +01:00
Fix bug with unicode-translated locale and wicd-curses
This commit is contained in:
@@ -146,7 +146,7 @@ def check_for_wireless(iwconfig, wireless_ip, set_status):
|
|||||||
if not network:
|
if not network:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
network = unicode(network)
|
network = misc.to_unicode(network)
|
||||||
if daemon.GetSignalDisplayType() == 0:
|
if daemon.GetSignalDisplayType() == 0:
|
||||||
strength = wireless.GetCurrentSignalStrength(iwconfig)
|
strength = wireless.GetCurrentSignalStrength(iwconfig)
|
||||||
else:
|
else:
|
||||||
@@ -154,12 +154,12 @@ def check_for_wireless(iwconfig, wireless_ip, set_status):
|
|||||||
|
|
||||||
if strength is None:
|
if strength is None:
|
||||||
return False
|
return False
|
||||||
strength = str(strength)
|
strength = misc.to_unicode(daemon.FormatSignalForPrinting(strength))
|
||||||
ip = str(wireless_ip)
|
ip = misc.to_unicode(wireless_ip)
|
||||||
set_status(_('Connected to $A at $B (IP: $C)').replace
|
set_status(_('Connected to $A at $B (IP: $C)').replace
|
||||||
('$A', network).replace
|
('$A', network).replace
|
||||||
('$B', daemon.FormatSignalForPrinting(strength)).replace
|
('$B', strength).replace
|
||||||
('$C', wireless_ip))
|
('$C', ip))
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user