1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-20 21:08:06 +01:00

fixed bug where wired icon wouldn't change if cable became unplugged, fixed yet another indentation screw up

This commit is contained in:
imdano
2007-07-17 08:03:16 +00:00
parent 5bd069702d
commit e7fd625617

View File

@@ -87,13 +87,16 @@ def set_signal_image():
config.DisableLogging()
wired_ip = wired.GetWiredIP()
if wired.CheckPluggedIn() == True and wired_ip:
if wired.CheckPluggedIn() == True and wired_ip != None:
if stillWired == False: # Only set image/tooltip if it hasn't been set already
tr.set_from_file("images/wired.png")
tr.set_tooltip(language['connected_to_wired'].replace('$A',wired_ip))
stillWired = True
lock = ''
else:
if stillWired == True:
tr.set_from_file("images/no-signal.png")
tr.set_tooltip(language['not_connected'])
stillWired = False
wireless_ip = wireless.GetWirelessIP()
#If ip returns as None, we are probably returning from hibernation and need to force signal to 0 to avoid crashing