diff options
-rw-r--r-- | tests/auto/quick/qquickpositioners/data/transitions.qml | 18 | ||||
-rw-r--r-- | tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp | 4 |
2 files changed, 12 insertions, 10 deletions
diff --git a/tests/auto/quick/qquickpositioners/data/transitions.qml b/tests/auto/quick/qquickpositioners/data/transitions.qml index 54f5705c68..e7570de70c 100644 --- a/tests/auto/quick/qquickpositioners/data/transitions.qml +++ b/tests/auto/quick/qquickpositioners/data/transitions.qml @@ -7,6 +7,8 @@ Rectangle { property int duration: 50 + property real incrementalSize: 5 + property int targetTransitionsDone property int displaceTransitionsDone @@ -88,8 +90,8 @@ Rectangle { Rectangle { property string nameData: name objectName: "wrapper" - width: 30 + index*5 - height: 30 + index*5 + width: 30 + index*root.incrementalSize + height: 30 + index*root.incrementalSize border.width: 1 Column { Text { text: index } @@ -117,8 +119,8 @@ Rectangle { Rectangle { property string nameData: name objectName: "wrapper" - width: 30 + index*5 - height: 30 + index*5 + width: 30 + index*root.incrementalSize + height: 30 + index*root.incrementalSize border.width: 1 Column { Text { text: index } @@ -146,8 +148,8 @@ Rectangle { Rectangle { property string nameData: name objectName: "wrapper" - width: 30 + index*5 - height: 30 + index*5 + width: 30 + index*root.incrementalSize + height: 30 + index*root.incrementalSize border.width: 1 Column { Text { text: index } @@ -176,8 +178,8 @@ Rectangle { Rectangle { property string nameData: name objectName: "wrapper" - width: 30 + index*5 - height: 30 + index*5 + width: 30 + index*root.incrementalSize + height: 30 + index*root.incrementalSize border.width: 1 Column { Text { text: index } diff --git a/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp b/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp index 6ceacdfaf0..12b9d661d4 100644 --- a/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp +++ b/tests/auto/quick/qquickpositioners/tst_qquickpositioners.cpp @@ -596,7 +596,7 @@ void tst_qquickpositioners::addTransitions(const QString &positionerObjectName) matchItemLists(canvas->rootObject()->property("displacedTrans_targetItems").toList(), targetItems); } - checkItemPositions(positioner, &model, 5.0); // XXX fetch from qml? + checkItemPositions(positioner, &model, canvas->rootObject()->property("incrementalSize").toInt()); delete canvas; } @@ -702,7 +702,7 @@ void tst_qquickpositioners::moveTransitions(const QString &positionerObjectName) QCOMPARE(canvas->rootObject()->property("displacedTrans_targetItems").toList(), listOfEmptyObjectLists); } - checkItemPositions(positioner, &model, 5.0); + checkItemPositions(positioner, &model, canvas->rootObject()->property("incrementalSize").toInt()); delete canvas; } |