diff options
author | Ivan Alejandro <ivanalejandro0@gmail.com> | 2014-08-20 15:10:02 -0300 |
---|---|---|
committer | Ivan Alejandro <ivanalejandro0@gmail.com> | 2014-08-20 16:38:14 -0300 |
commit | b6ab5790e8b2ac0d67bf0eb40e474b8bed4c42dd (patch) | |
tree | 06eecf6a96567fcf5f282caffb463c843799f883 /src/leap/bitmask/gui/eip_preferenceswindow.py | |
parent | 20122b32ad799cf93d88c86c67d52cc7004d6af8 (diff) |
Select current provider on EIP preferences.
- Don't disconnect logout signals, so when the wizard is triggered the
UI can reflect the logout result.
- Restore the selected provider when 'other...' is selected *before* the
provider_changed signal is emitted to avoid that option to keep
selected in case of some error.
- Avoid the currentIndexChanged to be triggered when we load the providers.
Diffstat (limited to 'src/leap/bitmask/gui/eip_preferenceswindow.py')
-rw-r--r-- | src/leap/bitmask/gui/eip_preferenceswindow.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/leap/bitmask/gui/eip_preferenceswindow.py b/src/leap/bitmask/gui/eip_preferenceswindow.py index 0f63972f..b5788f3c 100644 --- a/src/leap/bitmask/gui/eip_preferenceswindow.py +++ b/src/leap/bitmask/gui/eip_preferenceswindow.py @@ -116,11 +116,14 @@ class EIPPreferencesWindow(QtGui.QDialog): self.ui.gbGatewaySelector.setEnabled(False) return + # block signals so the currentIndexChanged slot doesn't get triggered + self.ui.cbProvidersGateway.blockSignals(True) for provider, is_initialized in providers: label = provider if not is_initialized: label += self.tr(" (uninitialized)") self.ui.cbProvidersGateway.addItem(label, userData=provider) + self.ui.cbProvidersGateway.blockSignals(False) # Select provider by name domain = self._selected_domain |