summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/gui/mainwindow.py
diff options
context:
space:
mode:
authorTomás Touceda <chiiph@leap.se>2013-10-14 16:22:29 -0300
committerTomás Touceda <chiiph@leap.se>2013-10-14 16:22:29 -0300
commit228f0c41f088eb15fd3125894adaad4868c74ddd (patch)
tree8e4d44b69d1f7dc8093c7bd20e8bdda7c8ffbfc7 /src/leap/bitmask/gui/mainwindow.py
parent83d18a36423736b3e703c9f3d3dccd619d3fa335 (diff)
parent0935a0f0b7ba3e53cba0914db8efbeb0960b77cb (diff)
Merge remote-tracking branch 'ivan/bug/4143_display-first-run' into develop
Diffstat (limited to 'src/leap/bitmask/gui/mainwindow.py')
-rw-r--r--src/leap/bitmask/gui/mainwindow.py12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/leap/bitmask/gui/mainwindow.py b/src/leap/bitmask/gui/mainwindow.py
index 69545751..bb5c4e64 100644
--- a/src/leap/bitmask/gui/mainwindow.py
+++ b/src/leap/bitmask/gui/mainwindow.py
@@ -365,7 +365,12 @@ class MainWindow(QtGui.QMainWindow):
"""
if self._wizard_firstrun:
self._settings.set_properprovider(False)
- self.quit()
+ providers = self._settings.get_configured_providers()
+ has_provider_on_disk = len(providers) != 0
+ if not has_provider_on_disk:
+ # if we don't have any provider configured (included a pinned
+ # one) we can't use the application, so quit.
+ self.quit()
else:
self._finish_init()
@@ -393,6 +398,7 @@ class MainWindow(QtGui.QMainWindow):
if IS_MAC:
self._wizard.raise_()
self._wizard.finished.connect(self._wizard_finished)
+ self._settings.set_skip_first_run(True)
def _wizard_finished(self):
"""
@@ -783,8 +789,8 @@ class MainWindow(QtGui.QMainWindow):
"""
providers = self._settings.get_configured_providers()
has_provider_on_disk = len(providers) != 0
- is_proper_provider = self._settings.get_properprovider()
- return not (has_provider_on_disk and is_proper_provider)
+ skip_first_run = self._settings.get_skip_first_run()
+ return not (has_provider_on_disk and skip_first_run)
def _download_provider_config(self):
"""