Files
sqlitebrowser/src/RemotePushDialog.ui
Martin Kleusberg a0b87688ab dbhub: Attempt to fix the OK button in the Push dialog
The OK button in the Remote Push dialog sometimes needed to be clicked
twice in order to work. That's because whenever the Database Name field
loses focus, we would send out a request for the updated branch list.
While processing this request the OK button is effectively disabled by
Qt. This commit aims for an easy fix by changing the request to happen
whenever the text in the Name field changes. This way the timing is a
lot less sensitive. We will need to see however if this introduces other
timing issues for users with slow Internet connections.
2019-01-13 16:32:34 +01:00

283 lines
7.3 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>RemotePushDialog</class>
<widget class="QDialog" name="RemotePushDialog">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>583</width>
<height>300</height>
</rect>
</property>
<property name="windowTitle">
<string>Push database</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<layout class="QFormLayout" name="formLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Database na&amp;me to push to</string>
</property>
<property name="buddy">
<cstring>editName</cstring>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="editName">
<property name="maxLength">
<number>256</number>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Commit message</string>
</property>
<property name="buddy">
<cstring>editCommitMessage</cstring>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QTextEdit" name="editCommitMessage">
<property name="html">
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Oxygen-Sans'; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="acceptRichText">
<bool>false</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Database licence</string>
</property>
<property name="buddy">
<cstring>comboLicence</cstring>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QComboBox" name="comboLicence">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Public</string>
</property>
<property name="buddy">
<cstring>checkPublic</cstring>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QCheckBox" name="checkPublic"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Branch</string>
</property>
<property name="buddy">
<cstring>comboBranch</cstring>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="comboBranch">
<property name="editable">
<bool>true</bool>
</property>
<property name="duplicatesEnabled">
<bool>true</bool>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Force push</string>
</property>
<property name="buddy">
<cstring>checkForce</cstring>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QCheckBox" name="checkForce"/>
</item>
</layout>
</item>
<item>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>
</layout>
</widget>
<tabstops>
<tabstop>editName</tabstop>
<tabstop>editCommitMessage</tabstop>
<tabstop>comboBranch</tabstop>
<tabstop>checkPublic</tabstop>
<tabstop>comboLicence</tabstop>
</tabstops>
<resources/>
<connections>
<connection>
<sender>buttonBox</sender>
<signal>accepted()</signal>
<receiver>RemotePushDialog</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
<x>248</x>
<y>254</y>
</hint>
<hint type="destinationlabel">
<x>157</x>
<y>274</y>
</hint>
</hints>
</connection>
<connection>
<sender>buttonBox</sender>
<signal>rejected()</signal>
<receiver>RemotePushDialog</receiver>
<slot>reject()</slot>
<hints>
<hint type="sourcelabel">
<x>316</x>
<y>260</y>
</hint>
<hint type="destinationlabel">
<x>286</x>
<y>274</y>
</hint>
</hints>
</connection>
<connection>
<sender>editName</sender>
<signal>textChanged(QString)</signal>
<receiver>RemotePushDialog</receiver>
<slot>checkInput()</slot>
<hints>
<hint type="sourcelabel">
<x>201</x>
<y>25</y>
</hint>
<hint type="destinationlabel">
<x>217</x>
<y>3</y>
</hint>
</hints>
</connection>
<connection>
<sender>checkPublic</sender>
<signal>toggled(bool)</signal>
<receiver>RemotePushDialog</receiver>
<slot>checkInput()</slot>
<hints>
<hint type="sourcelabel">
<x>171</x>
<y>176</y>
</hint>
<hint type="destinationlabel">
<x>210</x>
<y>175</y>
</hint>
</hints>
</connection>
<connection>
<sender>editCommitMessage</sender>
<signal>textChanged()</signal>
<receiver>RemotePushDialog</receiver>
<slot>checkInput()</slot>
<hints>
<hint type="sourcelabel">
<x>175</x>
<y>113</y>
</hint>
<hint type="destinationlabel">
<x>91</x>
<y>111</y>
</hint>
</hints>
</connection>
<connection>
<sender>editName</sender>
<signal>textChanged(QString)</signal>
<receiver>RemotePushDialog</receiver>
<slot>reloadBranchList()</slot>
<hints>
<hint type="sourcelabel">
<x>176</x>
<y>25</y>
</hint>
<hint type="destinationlabel">
<x>77</x>
<y>3</y>
</hint>
</hints>
</connection>
<connection>
<sender>comboBranch</sender>
<signal>currentTextChanged(QString)</signal>
<receiver>RemotePushDialog</receiver>
<slot>checkInput()</slot>
<hints>
<hint type="sourcelabel">
<x>172</x>
<y>138</y>
</hint>
<hint type="destinationlabel">
<x>33</x>
<y>151</y>
</hint>
</hints>
</connection>
<connection>
<sender>checkForce</sender>
<signal>toggled(bool)</signal>
<receiver>RemotePushDialog</receiver>
<slot>checkInput()</slot>
<hints>
<hint type="sourcelabel">
<x>168</x>
<y>240</y>
</hint>
<hint type="destinationlabel">
<x>62</x>
<y>229</y>
</hint>
</hints>
</connection>
</connections>
<slots>
<slot>checkInput()</slot>
<slot>reloadBranchList()</slot>
</slots>
</ui>