diff options
author | kali <kali@leap.se> | 2012-10-08 07:57:42 +0900 |
---|---|---|
committer | kali <kali@leap.se> | 2012-10-08 07:57:42 +0900 |
commit | 4d195cd5b6e6600ccf0df78946cab6038a1fcaec (patch) | |
tree | 1362b2844f7e008cad8c29f26861566129af6edd /src/leap/baseapp/systray.py | |
parent | 3a77603eae5fea0b1efb226860e0264ccf96f41b (diff) | |
parent | 6728eb9afb21bad867e4052a6190a9bdb34c928a (diff) |
Merge branch 'feature/network_check' into develop
Conflicts:
src/leap/baseapp/mainwindow.py
src/leap/eip/tests/test_checks.py
Diffstat (limited to 'src/leap/baseapp/systray.py')
-rw-r--r-- | src/leap/baseapp/systray.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/leap/baseapp/systray.py b/src/leap/baseapp/systray.py index 0ab37f7f..1939bc09 100644 --- a/src/leap/baseapp/systray.py +++ b/src/leap/baseapp/systray.py @@ -163,9 +163,10 @@ class StatusAwareTrayIconMixin(object): oldlayout.itemAt(new).widget().show() def setIcon(self, name): - icon = self.Icons.get(name)(self) - self.trayIcon.setIcon(icon) - #self.setWindowIcon(icon) + icon_fun = self.Icons.get(name) + if icon_fun and callable(icon_fun): + icon = icon_fun(self) + self.trayIcon.setIcon(icon) def getIcon(self, icon_name): return self.states.get(icon_name, None) |