summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Brasser <michael.brasser@nokia.com>2010-08-13 02:22:46 (GMT)
committerMichael Brasser <michael.brasser@nokia.com>2010-08-13 02:28:58 (GMT)
commitf9fe93e6e85294274d4e0ce81db09783cfacd733 (patch)
treedc71ee15b779379ea262f404d0209a6f0f9a5a2a /src
parentd904fe2273be5d39b54b987eef6b9cc0d1b85c4b (diff)
downloadQt-f9fe93e6e85294274d4e0ce81db09783cfacd733.zip
Qt-f9fe93e6e85294274d4e0ce81db09783cfacd733.tar.gz
Qt-f9fe93e6e85294274d4e0ce81db09783cfacd733.tar.bz2
Clear previous animation data for non-triggering animations.
We need to clear the data from the last run if the animation doesn't match any of the state actions (or if there are no actions). Task-number: QTBUG-12805
Diffstat (limited to 'src')
-rw-r--r--src/declarative/util/qdeclarativeanimation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp
index a747706..2fca09d 100644
--- a/src/declarative/util/qdeclarativeanimation.cpp
+++ b/src/declarative/util/qdeclarativeanimation.cpp
@@ -2392,6 +2392,8 @@ void QDeclarativePropertyAnimation::transition(QDeclarativeStateActions &actions
d->actions = &data->actions;
} else {
delete data;
+ d->va->setFromSourcedValue(0); //clear previous data
+ d->va->setAnimValue(0, QAbstractAnimation::DeleteWhenStopped); //clear previous data
d->actions = 0;
}
}