![]() |
Qt 6.x
The Qt SDK
|
Public Types | |
enum | Mode { Track , Velocity , Spring } |
typedef QHash< QQmlProperty, QSpringAnimation * > | ActiveAnimationHash |
typedef ActiveAnimationHash::Iterator | ActiveAnimationHashIt |
![]() | |
enum | Direction { Forward , Backward } |
enum | State { Stopped , Paused , Running } |
enum | ChangeType { Completion = 0x01 , StateChange = 0x02 , CurrentLoop = 0x04 , CurrentTime = 0x08 } |
Public Attributes | |
qreal | currentValue |
qreal | to |
qreal | velocity |
int | startTime |
int | dura |
int | lastTime |
int | stopTime |
Mode | mode |
QQmlProperty | target |
qreal | velocityms |
qreal | maxVelocity |
qreal | mass |
qreal | spring |
qreal | damping |
qreal | epsilon |
qreal | modulus |
bool | useMass: 1 |
bool | haveModulus: 1 |
bool | skipUpdate: 1 |
![]() | |
SelfDeletable | m_selfDeletable |
Protected Member Functions | |
void | updateCurrentTime (int time) override |
void | updateState (QAbstractAnimationJob::State, QAbstractAnimationJob::State) override |
void | debugAnimation (QDebug d) const override |
![]() | |
virtual void | updateCurrentTime (int) |
virtual void | updateLoopCount (int) |
virtual void | updateState (QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState) |
virtual void | updateDirection (QAbstractAnimationJob::Direction direction) |
virtual void | topLevelAnimationLoopChanged () |
virtual void | debugAnimation (QDebug d) const |
void | fireTopLevelAnimationLoopChanged () |
void | setState (QAbstractAnimationJob::State state) |
void | finished () |
void | stateChanged (QAbstractAnimationJob::State newState, QAbstractAnimationJob::State oldState) |
void | currentLoopChanged () |
void | directionChanged (QAbstractAnimationJob::Direction) |
void | currentTimeChanged (int currentTime) |
Additional Inherited Members | |
![]() | |
int | m_loopCount |
QAnimationGroupJob * | m_group |
QAbstractAnimationJob::Direction | m_direction |
QAbstractAnimationJob::State | m_state |
int | m_totalCurrentTime |
int | m_currentTime |
int | m_currentLoop |
int | m_uncontrolledFinishTime |
int | m_currentLoopStartTime |
std::vector< ChangeListener > | changeListeners |
QQmlAnimationTimer * | m_timer = nullptr |
bool | m_hasRegisteredTimer:1 |
bool | m_isPause:1 |
bool | m_isGroup:1 |
bool | m_disableUserControl:1 |
bool | m_hasCurrentTimeChangeListeners:1 |
bool | m_isRenderThreadJob:1 |
bool | m_isRenderThreadProxy:1 |
Definition at line 21 of file qquickspringanimation.cpp.
Definition at line 58 of file qquickspringanimation.cpp.
Definition at line 59 of file qquickspringanimation.cpp.
Enumerator | |
---|---|
Track | |
Velocity | |
Spring |
Definition at line 39 of file qquickspringanimation.cpp.
QSpringAnimation::QSpringAnimation | ( | QQuickSpringAnimationPrivate * | priv = nullptr | ) |
Definition at line 107 of file qquickspringanimation.cpp.
QSpringAnimation::~QSpringAnimation | ( | ) |
Definition at line 131 of file qquickspringanimation.cpp.
References QQuickSpringAnimationPrivate::activeAnimations, QHash< Key, T >::begin(), QHash< Key, T >::end(), QHash< Key, T >::erase(), QHash< Key, T >::find(), and it.
|
inline |
Definition at line 61 of file qquickspringanimation.cpp.
Reimplemented from QAbstractAnimationJob.
Definition at line 284 of file qquickspringanimation.cpp.
References d, damping, Qt::dec(), epsilon, Qt::hex(), mass, maxVelocity, modulus, spring, to, and velocity.
|
overridevirtual |
Reimplemented from QAbstractAnimationJob.
Definition at line 150 of file qquickspringanimation.cpp.
void QSpringAnimation::init | ( | ) |
Definition at line 166 of file qquickspringanimation.cpp.
References lastTime, startTime, and stopTime.
Referenced by restart(), and updateState().
void QSpringAnimation::restart | ( | ) |
Definition at line 155 of file qquickspringanimation.cpp.
References DELAY_STOP_TIMER_INTERVAL, QElapsedTimer::elapsed(), QQuickSpringAnimationPrivate::elapsed, init(), QAbstractAnimationJob::isRunning(), skipUpdate, and stopTime.
|
overrideprotectedvirtual |
Reimplemented from QAbstractAnimationJob.
Definition at line 172 of file qquickspringanimation.cpp.
References QQmlPropertyData::BypassInterceptor, currentValue, damping, QQmlPropertyData::DontRemoveBinding, dura, QElapsedTimer::elapsed(), elapsed(), QQuickSpringAnimationPrivate::elapsed, epsilon, haveModulus, i, lastTime, mass, maxVelocity, modulus, qAbs(), skipUpdate, Spring, spring, startTime, QAbstractAnimationJob::stop(), stopTime, time, to, Track, useMass, velocity, velocityms, and QQmlPropertyPrivate::write().
|
overrideprotectedvirtual |
Reimplemented from QAbstractAnimationJob.
Definition at line 278 of file qquickspringanimation.cpp.
References init(), newState(), and QAbstractAnimationJob::Running.
qreal QSpringAnimation::currentValue |
Definition at line 32 of file qquickspringanimation.cpp.
Referenced by updateCurrentTime().
qreal QSpringAnimation::damping |
Definition at line 51 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
int QSpringAnimation::dura |
Definition at line 36 of file qquickspringanimation.cpp.
Referenced by updateCurrentTime().
qreal QSpringAnimation::epsilon |
Definition at line 52 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
bool QSpringAnimation::haveModulus |
Definition at line 56 of file qquickspringanimation.cpp.
Referenced by updateCurrentTime().
int QSpringAnimation::lastTime |
Definition at line 37 of file qquickspringanimation.cpp.
Referenced by init(), and updateCurrentTime().
qreal QSpringAnimation::mass |
Definition at line 49 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
qreal QSpringAnimation::maxVelocity |
Definition at line 48 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
Mode QSpringAnimation::mode |
Definition at line 44 of file qquickspringanimation.cpp.
qreal QSpringAnimation::modulus |
Definition at line 53 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
bool QSpringAnimation::skipUpdate |
Definition at line 57 of file qquickspringanimation.cpp.
Referenced by restart(), and updateCurrentTime().
qreal QSpringAnimation::spring |
Definition at line 50 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
int QSpringAnimation::startTime |
Definition at line 35 of file qquickspringanimation.cpp.
Referenced by init(), and updateCurrentTime().
int QSpringAnimation::stopTime |
Definition at line 38 of file qquickspringanimation.cpp.
Referenced by init(), restart(), and updateCurrentTime().
QQmlProperty QSpringAnimation::target |
Definition at line 45 of file qquickspringanimation.cpp.
qreal QSpringAnimation::to |
Definition at line 33 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
bool QSpringAnimation::useMass |
Definition at line 55 of file qquickspringanimation.cpp.
Referenced by updateCurrentTime().
qreal QSpringAnimation::velocity |
Definition at line 34 of file qquickspringanimation.cpp.
Referenced by debugAnimation(), and updateCurrentTime().
qreal QSpringAnimation::velocityms |
Definition at line 47 of file qquickspringanimation.cpp.
Referenced by updateCurrentTime().