From 4530e4c8cf1ddb1ac92fc04fa5d25b0b78308534 Mon Sep 17 00:00:00 2001 From: Michael Brasser Date: Tue, 18 May 2010 09:06:47 +1000 Subject: Set raster + gl viewport as the default for OS X. This setup seems to work around most rendering bugs and timing issues. Task-number: QTBUG-10544 --- tools/qml/main.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/qml/main.cpp b/tools/qml/main.cpp index 380f5cc..0ddce72 100644 --- a/tools/qml/main.cpp +++ b/tools/qml/main.cpp @@ -181,7 +181,7 @@ int main(int argc, char ** argv) atexit(showWarnings); #endif -#if defined (Q_WS_X11) +#if defined (Q_WS_X11) || defined (Q_WS_MAC) //### default to using raster graphics backend for now bool gsSpecified = false; for (int i = 0; i < argc; ++i) { @@ -236,6 +236,10 @@ int main(int argc, char ** argv) useNativeFileBrowser = false; #endif +#if defined(Q_WS_MAC) + useGL = true; +#endif + for (int i = 1; i < argc; ++i) { bool lastArg = (i == argc - 1); QString arg = argv[i]; -- cgit v0.12 From 273024e58d90bb9b3a5da0161f884f1af22d75df Mon Sep 17 00:00:00 2001 From: Michael Brasser Date: Tue, 18 May 2010 10:43:25 +1000 Subject: Use QDeclarativeScriptString for ParentChange. So that scope resolution is correct, e.g. "width: parent.width-10;" in a ParentChange works correctly. Task-number: QTBUG-10675 --- src/declarative/qml/qdeclarativecompiler.cpp | 2 +- .../util/qdeclarativestateoperations.cpp | 192 ++-- .../util/qdeclarativestateoperations_p.h | 36 +- .../qdeclarativelanguage/data/scriptString.3.qml | 5 + .../qdeclarativelanguage/data/scriptString.4.qml | 5 + .../qdeclarativelanguage/data/scriptString.5.qml | 5 + .../tst_qdeclarativelanguage.cpp | 53 +- .../parentAnimation2/data/parentAnimation2.0.png | Bin 0 -> 2046 bytes .../parentAnimation2/data/parentAnimation2.1.png | Bin 0 -> 2059 bytes .../parentAnimation2/data/parentAnimation2.2.png | Bin 0 -> 2052 bytes .../parentAnimation2/data/parentAnimation2.3.png | Bin 0 -> 2011 bytes .../parentAnimation2/data/parentAnimation2.qml | 1023 ++++++++++++++++++++ .../parentAnimation2/parentAnimation2.qml | 64 ++ tests/auto/declarative/qmlvisual/tst_qmlvisual.cpp | 1 + 14 files changed, 1301 insertions(+), 85 deletions(-) create mode 100644 tests/auto/declarative/qdeclarativelanguage/data/scriptString.3.qml create mode 100644 tests/auto/declarative/qdeclarativelanguage/data/scriptString.4.qml create mode 100644 tests/auto/declarative/qdeclarativelanguage/data/scriptString.5.qml create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.0.png create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.1.png create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.2.png create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.3.png create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.qml create mode 100644 tests/auto/declarative/qmlvisual/animation/parentAnimation2/parentAnimation2.qml diff --git a/src/declarative/qml/qdeclarativecompiler.cpp b/src/declarative/qml/qdeclarativecompiler.cpp index a43b9ac..19c12ff 100644 --- a/src/declarative/qml/qdeclarativecompiler.cpp +++ b/src/declarative/qml/qdeclarativecompiler.cpp @@ -1893,7 +1893,7 @@ bool QDeclarativeCompiler::buildScriptStringProperty(QDeclarativeParser::Propert if (prop->values.count() > 1) COMPILE_EXCEPTION(prop->values.at(1), tr( "Cannot assign multiple values to a script property")); - if (prop->values.at(0)->object || !prop->values.at(0)->value.isScript()) + if (prop->values.at(0)->object) COMPILE_EXCEPTION(prop->values.at(0), tr( "Invalid property assignment: script expected")); obj->addScriptStringProperty(prop, ctxt.stack); diff --git a/src/declarative/util/qdeclarativestateoperations.cpp b/src/declarative/util/qdeclarativestateoperations.cpp index 0326f6d..efef52d 100644 --- a/src/declarative/util/qdeclarativestateoperations.cpp +++ b/src/declarative/util/qdeclarativestateoperations.cpp @@ -75,12 +75,12 @@ public: QDeclarativeItem *rewindParent; QDeclarativeItem *rewindStackBefore; - QDeclarativeNullableValue x; - QDeclarativeNullableValue y; - QDeclarativeNullableValue width; - QDeclarativeNullableValue height; - QDeclarativeNullableValue scale; - QDeclarativeNullableValue rotation; + QDeclarativeNullableValue xString; + QDeclarativeNullableValue yString; + QDeclarativeNullableValue widthString; + QDeclarativeNullableValue heightString; + QDeclarativeNullableValue scaleString; + QDeclarativeNullableValue rotationString; void doChange(QDeclarativeItem *targetParent, QDeclarativeItem *stackBefore = 0); }; @@ -196,112 +196,112 @@ QDeclarativeParentChange::~QDeclarativeParentChange() These properties hold the new position, size, scale, and rotation for the item in this state. */ -qreal QDeclarativeParentChange::x() const +QDeclarativeScriptString QDeclarativeParentChange::x() const { Q_D(const QDeclarativeParentChange); - return d->x.isNull ? qreal(0.) : d->x.value; + return d->xString.value; } -void QDeclarativeParentChange::setX(qreal x) +void QDeclarativeParentChange::setX(QDeclarativeScriptString x) { Q_D(QDeclarativeParentChange); - d->x = x; + d->xString = x; } bool QDeclarativeParentChange::xIsSet() const { Q_D(const QDeclarativeParentChange); - return d->x.isValid(); + return d->xString.isValid(); } -qreal QDeclarativeParentChange::y() const +QDeclarativeScriptString QDeclarativeParentChange::y() const { Q_D(const QDeclarativeParentChange); - return d->y.isNull ? qreal(0.) : d->y.value; + return d->yString.value; } -void QDeclarativeParentChange::setY(qreal y) +void QDeclarativeParentChange::setY(QDeclarativeScriptString y) { Q_D(QDeclarativeParentChange); - d->y = y; + d->yString = y; } bool QDeclarativeParentChange::yIsSet() const { Q_D(const QDeclarativeParentChange); - return d->y.isValid(); + return d->yString.isValid(); } -qreal QDeclarativeParentChange::width() const +QDeclarativeScriptString QDeclarativeParentChange::width() const { Q_D(const QDeclarativeParentChange); - return d->width.isNull ? qreal(0.) : d->width.value; + return d->widthString.value; } -void QDeclarativeParentChange::setWidth(qreal width) +void QDeclarativeParentChange::setWidth(QDeclarativeScriptString width) { Q_D(QDeclarativeParentChange); - d->width = width; + d->widthString = width; } bool QDeclarativeParentChange::widthIsSet() const { Q_D(const QDeclarativeParentChange); - return d->width.isValid(); + return d->widthString.isValid(); } -qreal QDeclarativeParentChange::height() const +QDeclarativeScriptString QDeclarativeParentChange::height() const { Q_D(const QDeclarativeParentChange); - return d->height.isNull ? qreal(0.) : d->height.value; + return d->heightString.value; } -void QDeclarativeParentChange::setHeight(qreal height) +void QDeclarativeParentChange::setHeight(QDeclarativeScriptString height) { Q_D(QDeclarativeParentChange); - d->height = height; + d->heightString = height; } bool QDeclarativeParentChange::heightIsSet() const { Q_D(const QDeclarativeParentChange); - return d->height.isValid(); + return d->heightString.isValid(); } -qreal QDeclarativeParentChange::scale() const +QDeclarativeScriptString QDeclarativeParentChange::scale() const { Q_D(const QDeclarativeParentChange); - return d->scale.isNull ? qreal(1.) : d->scale.value; + return d->scaleString.value; } -void QDeclarativeParentChange::setScale(qreal scale) +void QDeclarativeParentChange::setScale(QDeclarativeScriptString scale) { Q_D(QDeclarativeParentChange); - d->scale = scale; + d->scaleString = scale; } bool QDeclarativeParentChange::scaleIsSet() const { Q_D(const QDeclarativeParentChange); - return d->scale.isValid(); + return d->scaleString.isValid(); } -qreal QDeclarativeParentChange::rotation() const +QDeclarativeScriptString QDeclarativeParentChange::rotation() const { Q_D(const QDeclarativeParentChange); - return d->rotation.isNull ? qreal(0.) : d->rotation.value; + return d->rotationString.value; } -void QDeclarativeParentChange::setRotation(qreal rotation) +void QDeclarativeParentChange::setRotation(QDeclarativeScriptString rotation) { Q_D(QDeclarativeParentChange); - d->rotation = rotation; + d->rotationString = rotation; } bool QDeclarativeParentChange::rotationIsSet() const { Q_D(const QDeclarativeParentChange); - return d->rotation.isValid(); + return d->rotationString.isValid(); } QDeclarativeItem *QDeclarativeParentChange::originalParent() const @@ -356,34 +356,118 @@ QDeclarativeStateOperation::ActionList QDeclarativeParentChange::actions() a.event = this; actions << a; - if (d->x.isValid()) { - QDeclarativeAction xa(d->target, QLatin1String("x"), x()); - actions << xa; + if (d->xString.isValid()) { + bool ok = false; + QString script = d->xString.value.script(); + qreal x = script.toFloat(&ok); + if (ok) { + QDeclarativeAction xa(d->target, QLatin1String("x"), x); + actions << xa; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("x"))); + QDeclarativeAction xa; + xa.property = newBinding->property(); + xa.toBinding = newBinding; + xa.fromValue = xa.property.read(); + xa.deletableToBinding = true; + actions << xa; + } } - if (d->y.isValid()) { - QDeclarativeAction ya(d->target, QLatin1String("y"), y()); - actions << ya; + if (d->yString.isValid()) { + bool ok = false; + QString script = d->yString.value.script(); + qreal y = script.toFloat(&ok); + if (ok) { + QDeclarativeAction ya(d->target, QLatin1String("y"), y); + actions << ya; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("y"))); + QDeclarativeAction ya; + ya.property = newBinding->property(); + ya.toBinding = newBinding; + ya.fromValue = ya.property.read(); + ya.deletableToBinding = true; + actions << ya; + } } - if (d->scale.isValid()) { - QDeclarativeAction sa(d->target, QLatin1String("scale"), scale()); - actions << sa; + if (d->scaleString.isValid()) { + bool ok = false; + QString script = d->scaleString.value.script(); + qreal scale = script.toFloat(&ok); + if (ok) { + QDeclarativeAction sa(d->target, QLatin1String("scale"), scale); + actions << sa; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("scale"))); + QDeclarativeAction sa; + sa.property = newBinding->property(); + sa.toBinding = newBinding; + sa.fromValue = sa.property.read(); + sa.deletableToBinding = true; + actions << sa; + } } - if (d->rotation.isValid()) { - QDeclarativeAction ra(d->target, QLatin1String("rotation"), rotation()); - actions << ra; + if (d->rotationString.isValid()) { + bool ok = false; + QString script = d->rotationString.value.script(); + qreal rotation = script.toFloat(&ok); + if (ok) { + QDeclarativeAction ra(d->target, QLatin1String("rotation"), rotation); + actions << ra; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("rotation"))); + QDeclarativeAction ra; + ra.property = newBinding->property(); + ra.toBinding = newBinding; + ra.fromValue = ra.property.read(); + ra.deletableToBinding = true; + actions << ra; + } } - if (d->width.isValid()) { - QDeclarativeAction wa(d->target, QLatin1String("width"), width()); - actions << wa; + if (d->widthString.isValid()) { + bool ok = false; + QString script = d->widthString.value.script(); + qreal width = script.toFloat(&ok); + if (ok) { + QDeclarativeAction wa(d->target, QLatin1String("width"), width); + actions << wa; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("width"))); + QDeclarativeAction wa; + wa.property = newBinding->property(); + wa.toBinding = newBinding; + wa.fromValue = wa.property.read(); + wa.deletableToBinding = true; + actions << wa; + } } - if (d->height.isValid()) { - QDeclarativeAction ha(d->target, QLatin1String("height"), height()); - actions << ha; + if (d->heightString.isValid()) { + bool ok = false; + QString script = d->heightString.value.script(); + qreal height = script.toFloat(&ok); + if (ok) { + QDeclarativeAction ha(d->target, QLatin1String("height"), height); + actions << ha; + } else { + QDeclarativeBinding *newBinding = new QDeclarativeBinding(script, d->target, qmlContext(this)); + newBinding->setTarget(QDeclarativeProperty(d->target, QLatin1String("height"))); + QDeclarativeAction ha; + ha.property = newBinding->property(); + ha.toBinding = newBinding; + ha.fromValue = ha.property.read(); + ha.deletableToBinding = true; + actions << ha; + } } return actions; diff --git a/src/declarative/util/qdeclarativestateoperations_p.h b/src/declarative/util/qdeclarativestateoperations_p.h index 21a86f5..05ad052 100644 --- a/src/declarative/util/qdeclarativestateoperations_p.h +++ b/src/declarative/util/qdeclarativestateoperations_p.h @@ -62,12 +62,12 @@ class Q_DECLARATIVE_EXPORT QDeclarativeParentChange : public QDeclarativeStateOp Q_PROPERTY(QDeclarativeItem *target READ object WRITE setObject) Q_PROPERTY(QDeclarativeItem *parent READ parent WRITE setParent) - Q_PROPERTY(qreal x READ x WRITE setX) - Q_PROPERTY(qreal y READ y WRITE setY) - Q_PROPERTY(qreal width READ width WRITE setWidth) - Q_PROPERTY(qreal height READ height WRITE setHeight) - Q_PROPERTY(qreal scale READ scale WRITE setScale) - Q_PROPERTY(qreal rotation READ rotation WRITE setRotation) + Q_PROPERTY(QDeclarativeScriptString x READ x WRITE setX) + Q_PROPERTY(QDeclarativeScriptString y READ y WRITE setY) + Q_PROPERTY(QDeclarativeScriptString width READ width WRITE setWidth) + Q_PROPERTY(QDeclarativeScriptString height READ height WRITE setHeight) + Q_PROPERTY(QDeclarativeScriptString scale READ scale WRITE setScale) + Q_PROPERTY(QDeclarativeScriptString rotation READ rotation WRITE setRotation) public: QDeclarativeParentChange(QObject *parent=0); ~QDeclarativeParentChange(); @@ -80,28 +80,28 @@ public: QDeclarativeItem *originalParent() const; - qreal x() const; - void setX(qreal x); + QDeclarativeScriptString x() const; + void setX(QDeclarativeScriptString x); bool xIsSet() const; - qreal y() const; - void setY(qreal y); + QDeclarativeScriptString y() const; + void setY(QDeclarativeScriptString y); bool yIsSet() const; - qreal width() const; - void setWidth(qreal width); + QDeclarativeScriptString width() const; + void setWidth(QDeclarativeScriptString width); bool widthIsSet() const; - qreal height() const; - void setHeight(qreal height); + QDeclarativeScriptString height() const; + void setHeight(QDeclarativeScriptString height); bool heightIsSet() const; - qreal scale() const; - void setScale(qreal scale); + QDeclarativeScriptString scale() const; + void setScale(QDeclarativeScriptString scale); bool scaleIsSet() const; - qreal rotation() const; - void setRotation(qreal rotation); + QDeclarativeScriptString rotation() const; + void setRotation(QDeclarativeScriptString rotation); bool rotationIsSet() const; virtual ActionList actions(); diff --git a/tests/auto/declarative/qdeclarativelanguage/data/scriptString.3.qml b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.3.qml new file mode 100644 index 0000000..0de3667 --- /dev/null +++ b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.3.qml @@ -0,0 +1,5 @@ +import Test 1.0 + +MyTypeObject { + scriptProperty: "hello world" +} diff --git a/tests/auto/declarative/qdeclarativelanguage/data/scriptString.4.qml b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.4.qml new file mode 100644 index 0000000..0cd82ff --- /dev/null +++ b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.4.qml @@ -0,0 +1,5 @@ +import Test 1.0 + +MyTypeObject { + scriptProperty: 12.345 +} diff --git a/tests/auto/declarative/qdeclarativelanguage/data/scriptString.5.qml b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.5.qml new file mode 100644 index 0000000..3e2f9a4 --- /dev/null +++ b/tests/auto/declarative/qdeclarativelanguage/data/scriptString.5.qml @@ -0,0 +1,5 @@ +import Test 1.0 + +MyTypeObject { + scriptProperty: true +} diff --git a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp index 6b070f5..4434e46 100644 --- a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp +++ b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp @@ -1105,19 +1105,48 @@ void tst_qdeclarativelanguage::onDestruction() // Check that assignments to QDeclarativeScriptString properties work void tst_qdeclarativelanguage::scriptString() { - QDeclarativeComponent component(&engine, TEST_FILE("scriptString.qml")); - VERIFY_ERRORS(0); + { + QDeclarativeComponent component(&engine, TEST_FILE("scriptString.qml")); + VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->scriptProperty().script(), QString("foo + bar")); - QCOMPARE(object->scriptProperty().scopeObject(), qobject_cast(object)); - QCOMPARE(object->scriptProperty().context(), qmlContext(object)); - - QVERIFY(object->grouped() != 0); - QCOMPARE(object->grouped()->script().script(), QString("console.log(1921)")); - QCOMPARE(object->grouped()->script().scopeObject(), qobject_cast(object)); - QCOMPARE(object->grouped()->script().context(), qmlContext(object)); + MyTypeObject *object = qobject_cast(component.create()); + QVERIFY(object != 0); + QCOMPARE(object->scriptProperty().script(), QString("foo + bar")); + QCOMPARE(object->scriptProperty().scopeObject(), qobject_cast(object)); + QCOMPARE(object->scriptProperty().context(), qmlContext(object)); + + QVERIFY(object->grouped() != 0); + QCOMPARE(object->grouped()->script().script(), QString("console.log(1921)")); + QCOMPARE(object->grouped()->script().scopeObject(), qobject_cast(object)); + QCOMPARE(object->grouped()->script().context(), qmlContext(object)); + } + + { + QDeclarativeComponent component(&engine, TEST_FILE("scriptString3.qml")); + VERIFY_ERRORS(0); + + MyTypeObject *object = qobject_cast(component.create()); + QVERIFY(object != 0); + QCOMPARE(object->scriptProperty().script(), QString("\"hello world\"")); + } + + { + QDeclarativeComponent component(&engine, TEST_FILE("scriptString4.qml")); + VERIFY_ERRORS(0); + + MyTypeObject *object = qobject_cast(component.create()); + QVERIFY(object != 0); + QCOMPARE(object->scriptProperty().script(), QString("12.345")); + } + + { + QDeclarativeComponent component(&engine, TEST_FILE("scriptString5.qml")); + VERIFY_ERRORS(0); + + MyTypeObject *object = qobject_cast(component.create()); + QVERIFY(object != 0); + QCOMPARE(object->scriptProperty().script(), QString("true")); + } } // Check that default property assignments are correctly spliced into explicit diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.0.png b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.0.png new file mode 100644 index 0000000..135911c Binary files /dev/null and b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.0.png differ diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.1.png b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.1.png new file mode 100644 index 0000000..0d71292 Binary files /dev/null and b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.1.png differ diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.2.png b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.2.png new file mode 100644 index 0000000..920d992 Binary files /dev/null and b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.2.png differ diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.3.png b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.3.png new file mode 100644 index 0000000..1c4d89e Binary files /dev/null and b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.3.png differ diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.qml b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.qml new file mode 100644 index 0000000..9e1b923 --- /dev/null +++ b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/data/parentAnimation2.qml @@ -0,0 +1,1023 @@ +import Qt.VisualTest 4.7 + +VisualTest { + Frame { + msec: 0 + } + Frame { + msec: 16 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 32 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 48 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 64 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 80 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 96 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 112 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 128 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 144 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 160 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 176 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 192 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 208 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 224 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 240 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 256 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 272 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 288 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 304 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 320 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 336 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 352 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 368 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 384 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 400 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 416 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 432 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 448 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 464 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 480 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 496 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 512 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 528 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 544 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 560 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 576 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 592 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 608 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 624 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 640 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 656 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 672 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 688 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 704 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 350; y: 182 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 720 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 736 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 752 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 768 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 784 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 800 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 350; y: 182 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 816 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 832 + hash: "9b524b546d250d239ea99dd3319f3d6a" + } + Frame { + msec: 848 + hash: "593300f166c2fd3c325cb35114ca595b" + } + Frame { + msec: 864 + hash: "4451e76e111c99faa77b5fff9a2642fa" + } + Frame { + msec: 880 + hash: "0b4a5675afba935e17eba19e29b709ee" + } + Frame { + msec: 896 + hash: "8682866f0234eebf25aca27a7737c777" + } + Frame { + msec: 912 + hash: "5b3b70dd366bb4c1b5e7d56ce50e59a6" + } + Frame { + msec: 928 + hash: "897394982c93ebcbea68c25cec6d47d3" + } + Frame { + msec: 944 + hash: "23c3c0383a517d33767adeebc53bfa3a" + } + Frame { + msec: 960 + image: "parentAnimation2.0.png" + } + Frame { + msec: 976 + hash: "95b4fe1e5eeffe1673e199308e8ce76c" + } + Frame { + msec: 992 + hash: "dbb9a5aa9f569b97711aa2c1f5ebda47" + } + Frame { + msec: 1008 + hash: "0a5a73409b019e650ea860e1a8e27328" + } + Frame { + msec: 1024 + hash: "496bd0d053522bcf71d506b497ede0d5" + } + Frame { + msec: 1040 + hash: "97a32b4a6c99ffe842c35e903bd23d79" + } + Frame { + msec: 1056 + hash: "496dfbbb0c0c28e108adf4c25341ef11" + } + Frame { + msec: 1072 + hash: "aa2e5eb88b1498f0d36897be2a36b0ff" + } + Frame { + msec: 1088 + hash: "0c6f7b54264ab36cfd5145fb7b30432f" + } + Frame { + msec: 1104 + hash: "797fc3ea1db51f12d900b4e0e4998065" + } + Frame { + msec: 1120 + hash: "2b076b8bc1ec1e2f21a4d7a77c94cfeb" + } + Frame { + msec: 1136 + hash: "8d5888ca1cfba19cea569bd38bada417" + } + Frame { + msec: 1152 + hash: "15ae94de5aa106eaa18d0faefa5d61f5" + } + Frame { + msec: 1168 + hash: "96e90d74d5a7788d5a6da6cfdb92b185" + } + Frame { + msec: 1184 + hash: "5698a5e9e628209fc28644198eac65da" + } + Frame { + msec: 1200 + hash: "074ac8f08de8f22c241e23ad8b89b0f0" + } + Frame { + msec: 1216 + hash: "a49fdf41e9ee1e5d764262d4585af2ff" + } + Frame { + msec: 1232 + hash: "accc9b6573a676a40fcf0129085f6fce" + } + Frame { + msec: 1248 + hash: "1cc956d55f0c382c2f74dcc05a05494f" + } + Frame { + msec: 1264 + hash: "38ff3121566b2c719f47d027fcef8b8e" + } + Frame { + msec: 1280 + hash: "4de97b3361a16ca1710f2e75d5c9de6f" + } + Frame { + msec: 1296 + hash: "dbd1455105630bb8f262140e79ceda1b" + } + Frame { + msec: 1312 + hash: "bcdac4ab71a29b78bfa756b56b8d8414" + } + Frame { + msec: 1328 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1344 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1360 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1376 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1392 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1408 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1424 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1440 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1456 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1472 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1488 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1504 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1520 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1536 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1552 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1568 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1584 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1600 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1616 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1632 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1648 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1664 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1680 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1696 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1712 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 415; y: 121 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 1728 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1744 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1760 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1776 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1792 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1808 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1824 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 415; y: 121 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 1840 + hash: "f02f73a85532c1dd403d64c50c7e73ca" + } + Frame { + msec: 1856 + hash: "b59fbcfb7db77cf30ea4ff039a9163ae" + } + Frame { + msec: 1872 + hash: "432a76f0663bfd35f6bbeb3fbeb91799" + } + Frame { + msec: 1888 + hash: "098e18005d3a2ff9095587954c92339c" + } + Frame { + msec: 1904 + hash: "069100bf4ec523a9e9d5bf557ffc51d1" + } + Frame { + msec: 1920 + image: "parentAnimation2.1.png" + } + Frame { + msec: 1936 + hash: "60ed700e49bf2c51aba9b44400b56294" + } + Frame { + msec: 1952 + hash: "79aa15dc74668d963f36f28524f4d091" + } + Frame { + msec: 1968 + hash: "6838cb2d728259adc8d91a4a69e35adf" + } + Frame { + msec: 1984 + hash: "3f73c720ce5f1e65fb8537a9beb66d26" + } + Frame { + msec: 2000 + hash: "95d990ccd3e45e780d875aae1f4654f8" + } + Frame { + msec: 2016 + hash: "5389a121571f61e73903305860e60016" + } + Frame { + msec: 2032 + hash: "66f0018b6f35c1c18b28f4959eef96a8" + } + Frame { + msec: 2048 + hash: "c0fa0560a9a5a0f773394c4fd98c9fa3" + } + Frame { + msec: 2064 + hash: "e2d665ae0ac3007520003bb4a24ca708" + } + Frame { + msec: 2080 + hash: "ab6e6976e4214c725f71a4f0ba6d3f68" + } + Frame { + msec: 2096 + hash: "642f48f731f896d0d4b66956485b615b" + } + Frame { + msec: 2112 + hash: "cdc36222978e4361dd3ddc2cba78328d" + } + Frame { + msec: 2128 + hash: "22fe869d83d9d290c4d1702e7553c7aa" + } + Frame { + msec: 2144 + hash: "3cf2b6a4fd5c73c24717a1ce901cfb19" + } + Frame { + msec: 2160 + hash: "ea7ecad2a9b7e6ca9a9d1c9c46e0f6dc" + } + Frame { + msec: 2176 + hash: "3a7e7e2145b40732ef4e18218a959536" + } + Frame { + msec: 2192 + hash: "1386046373ab246ae533aba206ffe502" + } + Frame { + msec: 2208 + hash: "2183072e2117c2bc660767bc67e6c355" + } + Frame { + msec: 2224 + hash: "659c6fedf573d19727f9852a9034e4fe" + } + Frame { + msec: 2240 + hash: "5be4e8fa87593aeb4d59768a61441c37" + } + Frame { + msec: 2256 + hash: "2030b883508d07735b20726d218fd751" + } + Frame { + msec: 2272 + hash: "fd70334fa8a1ff80369cce6aa69255c4" + } + Frame { + msec: 2288 + hash: "be666aafc8a3d2de9ffaff54d9ac15d1" + } + Frame { + msec: 2304 + hash: "3370f2246f679068e40cdb48c92decad" + } + Frame { + msec: 2320 + hash: "f0b4565fd441c071112bdc8225861f76" + } + Frame { + msec: 2336 + hash: "61babd82afc20a3023c2fe483a2e73cb" + } + Frame { + msec: 2352 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2368 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2384 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2400 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2416 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2432 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2448 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2464 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2480 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2496 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2512 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2528 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2544 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2560 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2576 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2592 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2608 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2624 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2640 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2656 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2672 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2688 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2704 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2720 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2736 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2752 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2768 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Mouse { + type: 2 + button: 1 + buttons: 1 + x: 207; y: 255 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 2784 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2800 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2816 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2832 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2848 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2864 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2880 + image: "parentAnimation2.2.png" + } + Frame { + msec: 2896 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Mouse { + type: 3 + button: 1 + buttons: 0 + x: 207; y: 255 + modifiers: 0 + sendToViewport: true + } + Frame { + msec: 2912 + hash: "acab4a79f22ebc8a45759ae282e8f3db" + } + Frame { + msec: 2928 + hash: "608af88c841d6058c3304cc134de0187" + } + Frame { + msec: 2944 + hash: "96a727d6ff02c7baf85865fda9d871bd" + } + Frame { + msec: 2960 + hash: "22cacf109e40b457041d6c2862c4f97f" + } + Frame { + msec: 2976 + hash: "ea2a53381eef8ac75fce23c518f1e261" + } + Frame { + msec: 2992 + hash: "a719237e74e9c40b46cc1f27cca5e286" + } + Frame { + msec: 3008 + hash: "804ef3519ba9852afb0bd4ef793e0006" + } + Frame { + msec: 3024 + hash: "4abc5026f0de1165717bd14630c9d9f6" + } + Frame { + msec: 3040 + hash: "1e4dd04698691932725076073a0bd2e7" + } + Frame { + msec: 3056 + hash: "12aae9dcfd9597ce600588b19bdf5a7d" + } + Frame { + msec: 3072 + hash: "9176b69f7df68d860b7d7aecc2496f09" + } + Frame { + msec: 3088 + hash: "9cba95a510685ab6367ba87246f6c922" + } + Frame { + msec: 3104 + hash: "33ef448b9485fafb7a2af319f9f6e816" + } + Frame { + msec: 3120 + hash: "791760db748e46aceb9f469c33b7bf2f" + } + Frame { + msec: 3136 + hash: "201a00feef1bb445f2fd0ba8ef9467a1" + } + Frame { + msec: 3152 + hash: "6e8962c3cb522f5a45b093f1780d2dae" + } + Frame { + msec: 3168 + hash: "d75cb08203a4f2c05b4dfdca2196e3db" + } + Frame { + msec: 3184 + hash: "0417d681c9b64e2cc252ab6fcf20148b" + } + Frame { + msec: 3200 + hash: "85993e5a91a86cedb8c88819b035b6bb" + } + Frame { + msec: 3216 + hash: "d7a0db647e641df9625b8eb5078a8ec3" + } + Frame { + msec: 3232 + hash: "fa29824ed3fd3d4e0d8036079be6bcf8" + } + Frame { + msec: 3248 + hash: "4fc84a3ae74bb6ab7b0b846c8747eb54" + } + Frame { + msec: 3264 + hash: "a172921ffe15077382db8e8915fb340b" + } + Frame { + msec: 3280 + hash: "480ee71d2407d729814a2e19d4320c59" + } + Frame { + msec: 3296 + hash: "b8cf02a1ad96d5c3354f2b658085ed28" + } + Frame { + msec: 3312 + hash: "80fc0f57f58250f63a77b1988a9e1d2e" + } + Frame { + msec: 3328 + hash: "bc283b5d7c5b88ef447be5992a77b6a9" + } + Frame { + msec: 3344 + hash: "89c86df88dc1a3188d52c1f75b80ccf1" + } + Frame { + msec: 3360 + hash: "84148139d89b45949561321bd6f6c835" + } + Frame { + msec: 3376 + hash: "9118d6933b3f77e0b5b8da2d630152e8" + } + Frame { + msec: 3392 + hash: "2b5f746225053778fb07a606ff113e64" + } + Frame { + msec: 3408 + hash: "0a1ed1bea6ed674826d0a2c3146a1c31" + } + Frame { + msec: 3424 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3440 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3456 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3472 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3488 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3504 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3520 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3536 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3552 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3568 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3584 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3600 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3616 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3632 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3648 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Key { + type: 6 + key: 16777249 + modifiers: 67108864 + text: "" + autorep: false + count: 1 + } + Frame { + msec: 3664 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3680 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3696 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3712 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3728 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3744 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3760 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3776 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3792 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3808 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3824 + hash: "b3bfd7a06d3e246f4256ab5a267360b0" + } + Frame { + msec: 3840 + image: "parentAnimation2.3.png" + } +} diff --git a/tests/auto/declarative/qmlvisual/animation/parentAnimation2/parentAnimation2.qml b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/parentAnimation2.qml new file mode 100644 index 0000000..dfab108 --- /dev/null +++ b/tests/auto/declarative/qmlvisual/animation/parentAnimation2/parentAnimation2.qml @@ -0,0 +1,64 @@ +import Qt 4.7 + +/* +Blue rect fills (with 10px margin) screen, then red, then green, then screen again. +*/ + +Rectangle { + id: whiteRect + width: 640; height: 480; + + Rectangle { + id: redRect + x: 400; y: 50 + width: 100; height: 100 + color: "red" + } + + Rectangle { + id: greenRect + x: 100; y: 150 + width: 200; height: 300 + color: "green" + } + + Rectangle { + id: blueRect + x: 5; y: 5 + width: parent.width-10 + height: parent.height-10 + color: "lightblue" + + //Text { text: "Click me!"; anchors.centerIn: parent } + + MouseArea { + anchors.fill: parent + onClicked: { + switch(blueRect.state) { + case "": blueRect.state = "inRed"; break; + case "inRed": blueRect.state = "inGreen"; break; + case "inGreen": blueRect.state = ""; break; + } + } + } + + states: [ + State { + name: "inRed" + ParentChange { target: blueRect; parent: redRect; x: 5; y: 5; width: parent.width-10; height: parent.height-10 } + PropertyChanges { target: redRect; z: 1 } + }, + State { + name: "inGreen" + ParentChange { target: blueRect; parent: greenRect; x: 5; y: 5; width: parent.width-10; height: parent.height-10 } + PropertyChanges { target: greenRect; z: 1 } + } + ] + + transitions: Transition { + ParentAnimation { target: blueRect; //via: whiteRect; + NumberAnimation { properties: "x, y, width, height"; duration: 500 } + } + } + } +} diff --git a/tests/auto/declarative/qmlvisual/tst_qmlvisual.cpp b/tests/auto/declarative/qmlvisual/tst_qmlvisual.cpp index 4aad29b..f105692 100644 --- a/tests/auto/declarative/qmlvisual/tst_qmlvisual.cpp +++ b/tests/auto/declarative/qmlvisual/tst_qmlvisual.cpp @@ -105,6 +105,7 @@ void tst_qmlvisual::visual_data() files << QT_TEST_SOURCE_DIR "/qdeclarativeborderimage/animated.qml"; files << QT_TEST_SOURCE_DIR "/qdeclarativeflipable/test-flipable.qml"; files << QT_TEST_SOURCE_DIR "/qdeclarativepositioners/usingRepeater.qml"; + files << QT_TEST_SOURCE_DIR "/animation/parentAnimation2/parentAnimation2.qml"; //these are tests we think are stable and useful enough to be run by the CI system files << QT_TEST_SOURCE_DIR "/animation/bindinganimation/bindinganimation.qml"; -- cgit v0.12