File tree 3 files changed +25
-0
lines changed
3 files changed +25
-0
lines changed Original file line number Diff line number Diff line change @@ -126,6 +126,20 @@ void CIqBalance::on_doubleSpinBoxGain_valueChanged(double value)
126
126
}
127
127
128
128
129
+ /* ! \brief Revert button has been clicked.
130
+ *
131
+ * Revert I/Q correction values to the previously stored values.
132
+ */
133
+ void CIqBalance::on_revertButton_clicked ()
134
+ {
135
+ QSettings settings;
136
+ ui->doubleSpinBoxDCI ->setValue (settings.value (" DCICorr" ," 0.0" ).toDouble ());
137
+ ui->doubleSpinBoxDCQ ->setValue (settings.value (" DCQCorr" ," 0.0" ).toDouble ());
138
+ ui->doubleSpinBoxPhase ->setValue (settings.value (" PhaseCorr" ," 0.0" ).toDouble ());
139
+ ui->doubleSpinBoxGain ->setValue (settings.value (" GainCorr" ," 1.0" ).toDouble ());
140
+ }
141
+
142
+
129
143
/* ! \brief Reset button has been clicked. */
130
144
void CIqBalance::on_resetButton_clicked ()
131
145
{
Original file line number Diff line number Diff line change @@ -46,6 +46,7 @@ private slots:
46
46
void on_doubleSpinBoxDCQ_valueChanged (double value);
47
47
void on_doubleSpinBoxPhase_valueChanged (double value);
48
48
void on_doubleSpinBoxGain_valueChanged (double value);
49
+ void on_revertButton_clicked ();
49
50
void on_resetButton_clicked ();
50
51
51
52
private:
Original file line number Diff line number Diff line change @@ -173,6 +173,16 @@ p, li { white-space: pre-wrap; }
173
173
</property >
174
174
</widget >
175
175
</item >
176
+ <item row =" 2" column =" 1" >
177
+ <widget class =" QPushButton" name =" revertButton" >
178
+ <property name =" toolTip" >
179
+ <string >Revert to previously stored values</string >
180
+ </property >
181
+ <property name =" text" >
182
+ <string >Revert</string >
183
+ </property >
184
+ </widget >
185
+ </item >
176
186
</layout >
177
187
</widget >
178
188
</item >
You can’t perform that action at this time.
0 commit comments