diff options
author | Michael Brasser <michael.brasser@nokia.com> | 2010-04-09 03:42:22 (GMT) |
---|---|---|
committer | Michael Brasser <michael.brasser@nokia.com> | 2010-04-09 03:44:56 (GMT) |
commit | da56d7c25ce344128d827cfa2ed26f9eea437e4d (patch) | |
tree | 863bb2873aa12213b38c824940f8f58dc776d250 /src/declarative/util/qdeclarativestate.cpp | |
parent | 6e8342957d08d783c211fe0896c326aa44a13ee2 (diff) | |
download | Qt-da56d7c25ce344128d827cfa2ed26f9eea437e4d.zip Qt-da56d7c25ce344128d827cfa2ed26f9eea437e4d.tar.gz Qt-da56d7c25ce344128d827cfa2ed26f9eea437e4d.tar.bz2 |
Fix url resolution in PropertyChanges.
Make sure bindings in PropertyChanges resolve urls correctly. Also
refactor the code so that PropertyChanges will always use the
standard url resolution support provided by QDeclarativeProperty.
Task-number: QTBUG-9571
Diffstat (limited to 'src/declarative/util/qdeclarativestate.cpp')
-rw-r--r-- | src/declarative/util/qdeclarativestate.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/declarative/util/qdeclarativestate.cpp b/src/declarative/util/qdeclarativestate.cpp index e4c968e..78813fa 100644 --- a/src/declarative/util/qdeclarativestate.cpp +++ b/src/declarative/util/qdeclarativestate.cpp @@ -74,6 +74,18 @@ QDeclarativeAction::QDeclarativeAction(QObject *target, const QString &propertyN fromValue = property.read(); } +QDeclarativeAction::QDeclarativeAction(QObject *target, const QString &propertyName, + QDeclarativeContext *context, const QVariant &value) +: restore(true), actionDone(false), reverseEvent(false), deletableToBinding(false), + property(target, propertyName, context), toValue(value), + fromBinding(0), toBinding(0), event(0), + specifiedObject(target), specifiedProperty(propertyName) +{ + if (property.isValid()) + fromValue = property.read(); +} + + QDeclarativeActionEvent::~QDeclarativeActionEvent() { } |