File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -155,9 +155,15 @@ void QgsDoubleSpinBox::setLineEditAlignment( Qt::Alignment alignment )
155
155
void QgsDoubleSpinBox::setSpecialValueText ( const QString &txt )
156
156
{
157
157
if ( txt.isEmpty () )
158
+ {
158
159
QDoubleSpinBox::setSpecialValueText ( SPECIAL_TEXT_WHEN_EMPTY );
160
+ mLineEdit ->setNullValue ( SPECIAL_TEXT_WHEN_EMPTY );
161
+ }
159
162
else
163
+ {
160
164
QDoubleSpinBox::setSpecialValueText ( txt );
165
+ mLineEdit ->setNullValue ( SPECIAL_TEXT_WHEN_EMPTY );
166
+ }
161
167
}
162
168
163
169
QString QgsDoubleSpinBox::stripped ( const QString &originalText ) const
Original file line number Diff line number Diff line change @@ -152,9 +152,15 @@ void QgsSpinBox::setLineEditAlignment( Qt::Alignment alignment )
152
152
void QgsSpinBox::setSpecialValueText ( const QString &txt )
153
153
{
154
154
if ( txt.isEmpty () )
155
+ {
155
156
QSpinBox::setSpecialValueText ( SPECIAL_TEXT_WHEN_EMPTY );
157
+ mLineEdit ->setNullValue ( SPECIAL_TEXT_WHEN_EMPTY );
158
+ }
156
159
else
160
+ {
157
161
QSpinBox::setSpecialValueText ( txt );
162
+ mLineEdit ->setNullValue ( txt );
163
+ }
158
164
}
159
165
160
166
int QgsSpinBox::valueFromText ( const QString &text ) const
You can’t perform that action at this time.
0 commit comments