summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Alejandro <ivanalejandro0@gmail.com>2014-01-22 17:18:08 -0300
committerIvan Alejandro <ivanalejandro0@gmail.com>2014-01-22 17:18:08 -0300
commit1221160b11a32164c966cb1130bb3e0d74866d98 (patch)
treee8ccf9c6bcf83d6c1ae48ea374e3379ad48dbb84
parent8a05b6fcc913a21ce7b3fa950c63a2ebda76c6f2 (diff)
Select by default the use of an existing provider.
[Closes #4488]
-rw-r--r--changes/feature-4488_use-existing-provider-by-default1
-rw-r--r--src/leap/bitmask/gui/ui/wizard.ui73
-rw-r--r--src/leap/bitmask/gui/wizard.py4
3 files changed, 43 insertions, 35 deletions
diff --git a/changes/feature-4488_use-existing-provider-by-default b/changes/feature-4488_use-existing-provider-by-default
new file mode 100644
index 00000000..feeaa349
--- /dev/null
+++ b/changes/feature-4488_use-existing-provider-by-default
@@ -0,0 +1 @@
+- Wizard: select by default the use of an existing provider if we have configured at least one. Closes #4488.
diff --git a/src/leap/bitmask/gui/ui/wizard.ui b/src/leap/bitmask/gui/ui/wizard.ui
index cf591470..1ddd854f 100644
--- a/src/leap/bitmask/gui/ui/wizard.ui
+++ b/src/leap/bitmask/gui/ui/wizard.ui
@@ -269,7 +269,20 @@
<string>Configure or select a provider</string>
</property>
<layout class="QGridLayout" name="gridLayout_5">
- <item row="0" column="0">
+ <item row="5" column="1">
+ <widget class="QLineEdit" name="lnProvider"/>
+ </item>
+ <item row="5" column="0">
+ <widget class="QLabel" name="label">
+ <property name="text">
+ <string>https://</string>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+ </property>
+ </widget>
+ </item>
+ <item row="4" column="0">
<widget class="QRadioButton" name="rbNewProvider">
<property name="text">
<string>Configure new provider:</string>
@@ -279,30 +292,20 @@
</property>
</widget>
</item>
- <item row="2" column="0">
- <widget class="QRadioButton" name="rbExistingProvider">
+ <item row="5" column="2">
+ <widget class="QPushButton" name="btnCheck">
<property name="text">
- <string>Use existing one:</string>
+ <string>Check</string>
</property>
</widget>
</item>
- <item row="1" column="0">
- <widget class="QLabel" name="label">
+ <item row="2" column="0">
+ <widget class="QRadioButton" name="rbExistingProvider">
<property name="text">
- <string>https://</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+ <string>Use existing one:</string>
</property>
- </widget>
- </item>
- <item row="1" column="1">
- <widget class="QLineEdit" name="lnProvider"/>
- </item>
- <item row="1" column="2">
- <widget class="QPushButton" name="btnCheck">
- <property name="text">
- <string>Check</string>
+ <property name="checked">
+ <bool>false</bool>
</property>
</widget>
</item>
@@ -820,8 +823,8 @@
<slot>setFocus()</slot>
<hints>
<hint type="sourcelabel">
- <x>167</x>
- <y>192</y>
+ <x>174</x>
+ <y>174</y>
</hint>
<hint type="destinationlabel">
<x>265</x>
@@ -836,12 +839,12 @@
<slot>setFocus()</slot>
<hints>
<hint type="sourcelabel">
- <x>171</x>
- <y>164</y>
+ <x>174</x>
+ <y>227</y>
</hint>
<hint type="destinationlabel">
- <x>246</x>
- <y>164</y>
+ <x>425</x>
+ <y>254</y>
</hint>
</hints>
</connection>
@@ -852,12 +855,12 @@
<slot>setDisabled(bool)</slot>
<hints>
<hint type="sourcelabel">
- <x>169</x>
- <y>196</y>
+ <x>174</x>
+ <y>174</y>
</hint>
<hint type="destinationlabel">
- <x>327</x>
- <y>163</y>
+ <x>454</x>
+ <y>254</y>
</hint>
</hints>
</connection>
@@ -868,8 +871,8 @@
<slot>setDisabled(bool)</slot>
<hints>
<hint type="sourcelabel">
- <x>169</x>
- <y>162</y>
+ <x>174</x>
+ <y>227</y>
</hint>
<hint type="destinationlabel">
<x>269</x>
@@ -884,12 +887,12 @@
<slot>setDisabled(bool)</slot>
<hints>
<hint type="sourcelabel">
- <x>154</x>
- <y>193</y>
+ <x>169</x>
+ <y>174</y>
</hint>
<hint type="destinationlabel">
- <x>498</x>
- <y>170</y>
+ <x>520</x>
+ <y>255</y>
</hint>
</hints>
</connection>
diff --git a/src/leap/bitmask/gui/wizard.py b/src/leap/bitmask/gui/wizard.py
index b99e8db6..d5940c52 100644
--- a/src/leap/bitmask/gui/wizard.py
+++ b/src/leap/bitmask/gui/wizard.py
@@ -205,6 +205,10 @@ class Wizard(QtGui.QWizard):
random.shuffle(pinned) # don't prioritize alphabetically
self.ui.cbProviders.addItems(pinned)
+ # We have configured providers, so by default we select the
+ # 'Use existing provider' option.
+ self.ui.rbExistingProvider.setChecked(True)
+
def get_domain(self):
return self._domain