summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTomás Touceda <chiiph@leap.se>2014-07-24 16:33:25 -0300
committerTomás Touceda <chiiph@leap.se>2014-07-24 16:47:29 -0300
commit3a99419a4e55dd7675e5d57961bf42f2725251f1 (patch)
treedde6451f60df178450ea49db731d53a9c803c9b4 /src
parent44c2f71b84d37d55accb3052e0a3fe3dadd19298 (diff)
Improve hide and show main window on Ubuntu
Diffstat (limited to 'src')
-rw-r--r--src/leap/bitmask/gui/mainwindow.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py
index 53a7d95a..1bd39267 100644
--- a/src/leap/bitmask/gui/mainwindow.py
+++ b/src/leap/bitmask/gui/mainwindow.py
@@ -960,6 +960,12 @@ class MainWindow(QtGui.QMainWindow):
if not visible:
QtGui.QApplication.setQuitOnLastWindowClosed(True)
self.show()
+ if IS_LINUX:
+ # On ubuntu, activateWindow doesn't work reliably, so
+ # we do the following as a workaround. See
+ # https://bugreports.qt-project.org/browse/QTBUG-24932
+ # for more details
+ QtGui.QX11Info.setAppUserTime(0)
self.activateWindow()
self.raise_()
else: