From 3fe586a7aad16de5401090d3d1725e58fca0ed3e Mon Sep 17 00:00:00 2001 From: Ivan Alejandro Date: Tue, 22 Apr 2014 16:49:29 -0300 Subject: Add checks to avoid errors when ctrl-c in wizard. Check that systray exists, not the case during first run. Cleanup reactor stop code. Closes #5559. --- src/leap/bitmask/gui/mainwindow.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/leap/bitmask/gui/mainwindow.py') diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py index 907d4ceb..e4443434 100644 --- a/src/leap/bitmask/gui/mainwindow.py +++ b/src/leap/bitmask/gui/mainwindow.py @@ -2046,9 +2046,10 @@ class MainWindow(QtGui.QMainWindow): # first thing to do quitting, hide the mainwindow and show tooltip. self.hide() - self._systray.showMessage( - self.tr('Quitting...'), - self.tr('The app is quitting, please wait.')) + if self._systray is not None: + self._systray.showMessage( + self.tr('Quitting...'), + self.tr('The app is quitting, please wait.')) # explicitly process events to display tooltip immediately QtCore.QCoreApplication.processEvents() -- cgit v1.2.3