diff options
author | Mitch Curtis <mitch.curtis@theqtcompany.com> | 2015-05-22 13:03:25 +0200 |
---|---|---|
committer | Jani Heikkinen <jani.heikkinen@theqtcompany.com> | 2015-06-03 04:29:06 +0000 |
commit | db9be0a9d6195bc52415ce28d605ace149d02782 (patch) | |
tree | a1b0dd262e53a08f7015efc8fb8a32ad0b82db9e /tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp | |
parent | db525935ccd64d2c5c674f8a66dbe7096d754e9f (diff) |
Add left, right, top and bottom properties to basic QML rect type.
Task-number: QTBUG-45528
Task-number: QTBUG-45530
Change-Id: I83c4056b4bde37ef2dc4424ffddd823c1654d92e
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp')
-rw-r--r-- | tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp b/tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp index 2892e746da..578004b0a1 100644 --- a/tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp +++ b/tests/auto/qml/qqmlvaluetypes/tst_qqmlvaluetypes.cpp @@ -371,6 +371,10 @@ void tst_qqmlvaluetypes::rect() QCOMPARE(object->property("r_y").toInt(), 3); QCOMPARE(object->property("r_width").toInt(), 109); QCOMPARE(object->property("r_height").toInt(), 102); + QCOMPARE(object->property("r_left").toInt(), 2); + QCOMPARE(object->property("r_right").toInt(), 110); + QCOMPARE(object->property("r_top").toInt(), 3); + QCOMPARE(object->property("r_bottom").toInt(), 104); QCOMPARE(object->property("copy"), QVariant(QRect(2, 3, 109, 102))); delete object; @@ -418,6 +422,10 @@ void tst_qqmlvaluetypes::rectf() QCOMPARE(float(object->property("r_y").toDouble()), float(99.2)); QCOMPARE(float(object->property("r_width").toDouble()), float(88.1)); QCOMPARE(float(object->property("r_height").toDouble()), float(77.6)); + QCOMPARE(float(object->property("r_left").toDouble()), float(103.8)); + QCOMPARE(float(object->property("r_right").toDouble()), float(191.9)); + QCOMPARE(float(object->property("r_top").toDouble()), float(99.2)); + QCOMPARE(float(object->property("r_bottom").toDouble()), float(176.8)); QCOMPARE(object->property("copy"), QVariant(QRectF(103.8, 99.2, 88.1, 77.6))); delete object; |