diff options
author | J-P Nurmi <jpnurmi@digia.com> | 2012-10-23 14:39:26 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-10-30 17:51:21 +0100 |
commit | 85a8df184b3aaa7f3a5a35895aa1caa3d4c39f42 (patch) | |
tree | f6fc34d0a08ab464dd93a88a4a67911444bcb42f /src/widgets/styles/qstyleanimation_p.h | |
parent | 788e1b2ffa5541b86f62bf468540bb8b5872c033 (diff) |
Add QNumberStyleAnimation for fading out scroll bars on Mac
Change-Id: I6a85ed069a418d62078af6490a3d3186d5599a95
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Diffstat (limited to 'src/widgets/styles/qstyleanimation_p.h')
-rw-r--r-- | src/widgets/styles/qstyleanimation_p.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/widgets/styles/qstyleanimation_p.h b/src/widgets/styles/qstyleanimation_p.h index 3188eebebc..d9869533ef 100644 --- a/src/widgets/styles/qstyleanimation_p.h +++ b/src/widgets/styles/qstyleanimation_p.h @@ -110,6 +110,30 @@ private: mutable int _step; }; +class QNumberStyleAnimation : public QStyleAnimation +{ + Q_OBJECT + +public: + QNumberStyleAnimation(QObject *target); + + qreal startValue() const; + void setStartValue(qreal value); + + qreal endValue() const; + void setEndValue(qreal value); + + qreal currentValue() const; + +protected: + bool isUpdateNeeded() const; + +private: + qreal _start; + qreal _end; + mutable qreal _prev; +}; + QT_END_NAMESPACE #endif // QSTYLEANIMATION_P_H |