summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/gui
diff options
context:
space:
mode:
authorTomás Touceda <chiiph@leap.se>2014-07-28 17:54:54 -0300
committerTomás Touceda <chiiph@leap.se>2014-07-28 17:54:54 -0300
commit602f1afc87ad78deea9412385598526783557ae2 (patch)
treec9d28625b0b1838f4517a84f244c281fdbc76cc1 /src/leap/bitmask/gui
parenteafe21247a149d0c302e02007927ea25e65dca34 (diff)
parent72b6e999c883272cbe291ac610c528b5ae51077b (diff)
Merge remote-tracking branch 'refs/remotes/ivan/bug/5870_bitmask-prevent-system-logout-on-linux' into develop
Diffstat (limited to 'src/leap/bitmask/gui')
-rw-r--r--src/leap/bitmask/gui/mainwindow.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py
index 2f78fd14..4f7f519c 100644
--- a/src/leap/bitmask/gui/mainwindow.py
+++ b/src/leap/bitmask/gui/mainwindow.py
@@ -1138,6 +1138,11 @@ class MainWindow(QtGui.QMainWindow):
"""
Reimplementation of closeEvent to close to tray
"""
+ if not e.spontaneous():
+ # if the system requested the `close` then we should quit.
+ self.quit()
+ return
+
if QtGui.QSystemTrayIcon.isSystemTrayAvailable() and \
not self._really_quit:
self._toggle_visible()