File tree Expand file tree Collapse file tree 6 files changed +16
-0
lines changed Expand file tree Collapse file tree 6 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -57,4 +57,5 @@ class QgsDoubleSpinBox : QDoubleSpinBox
57
57
protected:
58
58
virtual void resizeEvent( QResizeEvent* event );
59
59
virtual void changeEvent( QEvent* event );
60
+ virtual void paintEvent( QPaintEvent* event );
60
61
};
Original file line number Diff line number Diff line change @@ -57,4 +57,5 @@ class QgsSpinBox : QSpinBox
57
57
protected:
58
58
virtual void resizeEvent( QResizeEvent* event );
59
59
virtual void changeEvent( QEvent* event );
60
+ virtual void paintEvent( QPaintEvent* event );
60
61
};
Original file line number Diff line number Diff line change @@ -63,6 +63,12 @@ void QgsDoubleSpinBox::changeEvent( QEvent *event )
63
63
mClearButton ->setVisible ( shouldShowClearForValue ( value () ) );
64
64
}
65
65
66
+ void QgsDoubleSpinBox::paintEvent ( QPaintEvent *event )
67
+ {
68
+ mClearButton ->setVisible ( shouldShowClearForValue ( value () ) );
69
+ QDoubleSpinBox::paintEvent ( event );
70
+ }
71
+
66
72
void QgsDoubleSpinBox::changed ( const double & value )
67
73
{
68
74
mClearButton ->setVisible ( shouldShowClearForValue ( value ) );
Original file line number Diff line number Diff line change @@ -82,6 +82,7 @@ class GUI_EXPORT QgsDoubleSpinBox : public QDoubleSpinBox
82
82
protected:
83
83
virtual void resizeEvent ( QResizeEvent* event ) override ;
84
84
virtual void changeEvent ( QEvent* event ) override ;
85
+ virtual void paintEvent ( QPaintEvent* event ) override ;
85
86
86
87
private slots:
87
88
void changed ( const double &value );
Original file line number Diff line number Diff line change @@ -63,6 +63,12 @@ void QgsSpinBox::changeEvent( QEvent *event )
63
63
mClearButton ->setVisible ( shouldShowClearForValue ( value () ) );
64
64
}
65
65
66
+ void QgsSpinBox::paintEvent ( QPaintEvent *event )
67
+ {
68
+ mClearButton ->setVisible ( shouldShowClearForValue ( value () ) );
69
+ QSpinBox::paintEvent ( event );
70
+ }
71
+
66
72
void QgsSpinBox::changed ( const int & value )
67
73
{
68
74
mClearButton ->setVisible ( shouldShowClearForValue ( value ) );
Original file line number Diff line number Diff line change @@ -81,6 +81,7 @@ class GUI_EXPORT QgsSpinBox : public QSpinBox
81
81
protected:
82
82
virtual void resizeEvent ( QResizeEvent* event ) override ;
83
83
virtual void changeEvent ( QEvent* event ) override ;
84
+ virtual void paintEvent ( QPaintEvent* event ) override ;
84
85
85
86
private slots:
86
87
void changed ( const int & value );
You can’t perform that action at this time.
0 commit comments