From da0e40dfefb7fc487a9a775363321e178e529d16 Mon Sep 17 00:00:00 2001 From: Michael Brasser Date: Mon, 12 Oct 2009 09:33:32 +1000 Subject: Make sure ParentChange always saves original parent. --- src/declarative/util/qmlstate.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/declarative/util/qmlstate.cpp b/src/declarative/util/qmlstate.cpp index 3c85db7..98facd9 100644 --- a/src/declarative/util/qmlstate.cpp +++ b/src/declarative/util/qmlstate.cpp @@ -350,6 +350,7 @@ void QmlState::apply(QmlStateGroup *group, QmlTransition *trans, QmlState *rever if (action.event) { if (!action.event->isReversable()) continue; + action.event->saveOriginals(); for (jj = 0; jj < d->revertList.count(); ++jj) { ActionEvent *event = d->revertList.at(jj).event; if (event && event->typeName() == action.event->typeName()) { @@ -359,9 +360,6 @@ void QmlState::apply(QmlStateGroup *group, QmlTransition *trans, QmlState *rever } } } - if (!found) - action.event->saveOriginals(); - //### do we ever need to do saveOriginals when found == true? } else { action.fromBinding = action.property.binding(); -- cgit v0.12