summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/declarative/util/qdeclarativesmoothedanimation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/declarative/util/qdeclarativesmoothedanimation.cpp b/src/declarative/util/qdeclarativesmoothedanimation.cpp
index f21b0c7..48a7583 100644
--- a/src/declarative/util/qdeclarativesmoothedanimation.cpp
+++ b/src/declarative/util/qdeclarativesmoothedanimation.cpp
@@ -69,6 +69,7 @@ QSmoothedAnimation::QSmoothedAnimation(QObject *parent)
void QSmoothedAnimation::restart()
{
+ initialVelocity = trackVelocity;
if (state() != QAbstractAnimation::Running)
start();
else
@@ -224,6 +225,7 @@ void QSmoothedAnimation::init()
QDeclarativePropertyPrivate::write(target, to,
QDeclarativePropertyPrivate::BypassInterceptor
| QDeclarativePropertyPrivate::DontRemoveBinding);
+ stop();
return;
case QDeclarativeSmoothedAnimation::Immediate:
initialVelocity = 0;