diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-12-17 14:46:56 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-12-17 14:46:56 (GMT) |
commit | 0d3786a9cd6dc3c4dd17a7e98fe138a7abaabb29 (patch) | |
tree | 6e362173db95836d41aa8124ed43ca810c030e95 | |
parent | 8dc7346e52d58efbacfee493c46df50920376bdf (diff) | |
parent | e0abcb2ff7a3044305580659f9a432a9630a5943 (diff) | |
download | Qt-0d3786a9cd6dc3c4dd17a7e98fe138a7abaabb29.zip Qt-0d3786a9cd6dc3c4dd17a7e98fe138a7abaabb29.tar.gz Qt-0d3786a9cd6dc3c4dd17a7e98fe138a7abaabb29.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/qt-qml into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/qt-qml:
Fix QDeclarativeState::reset() autotest
Update test bitmaps for QDeclarativeImage::svg() autotest on Linux
-rw-r--r-- | tests/auto/declarative/qdeclarativeimage/data/heart.png | bin | 12424 -> 12577 bytes | |||
-rw-r--r-- | tests/auto/declarative/qdeclarativeimage/data/heart200.png | bin | 7943 -> 8063 bytes | |||
-rw-r--r-- | tests/auto/declarative/qdeclarativestates/data/image.png | bin | 0 -> 173 bytes | |||
-rw-r--r-- | tests/auto/declarative/qdeclarativestates/data/reset.qml | 9 | ||||
-rw-r--r-- | tests/auto/declarative/qdeclarativestates/tst_qdeclarativestates.cpp | 13 |
5 files changed, 10 insertions, 12 deletions
diff --git a/tests/auto/declarative/qdeclarativeimage/data/heart.png b/tests/auto/declarative/qdeclarativeimage/data/heart.png Binary files differindex ff93f6c..abe97fe 100644 --- a/tests/auto/declarative/qdeclarativeimage/data/heart.png +++ b/tests/auto/declarative/qdeclarativeimage/data/heart.png diff --git a/tests/auto/declarative/qdeclarativeimage/data/heart200.png b/tests/auto/declarative/qdeclarativeimage/data/heart200.png Binary files differindex 5a31ae8..7fbb13c 100644 --- a/tests/auto/declarative/qdeclarativeimage/data/heart200.png +++ b/tests/auto/declarative/qdeclarativeimage/data/heart200.png diff --git a/tests/auto/declarative/qdeclarativestates/data/image.png b/tests/auto/declarative/qdeclarativestates/data/image.png Binary files differnew file mode 100644 index 0000000..ed1833c --- /dev/null +++ b/tests/auto/declarative/qdeclarativestates/data/image.png diff --git a/tests/auto/declarative/qdeclarativestates/data/reset.qml b/tests/auto/declarative/qdeclarativestates/data/reset.qml index 8799c97..a140ffa 100644 --- a/tests/auto/declarative/qdeclarativestates/data/reset.qml +++ b/tests/auto/declarative/qdeclarativestates/data/reset.qml @@ -3,17 +3,16 @@ import QtQuick 1.0 Rectangle { width: 640 height: 480 - Text { - id: theText + Image { + id: image width: 40 - wrapMode: Text.WordWrap - text: "a text string that is longer than 40 pixels" + source: "image.png" } states: State { name: "state1" PropertyChanges { - target: theText + target: image width: undefined } } diff --git a/tests/auto/declarative/qdeclarativestates/tst_qdeclarativestates.cpp b/tests/auto/declarative/qdeclarativestates/tst_qdeclarativestates.cpp index b8409a5..870842c 100644 --- a/tests/auto/declarative/qdeclarativestates/tst_qdeclarativestates.cpp +++ b/tests/auto/declarative/qdeclarativestates/tst_qdeclarativestates.cpp @@ -44,7 +44,6 @@ #include <private/qdeclarativeanchors_p_p.h> #include <private/qdeclarativerectangle_p.h> #include <private/qdeclarativeimage_p.h> -#include <private/qdeclarativetext_p.h> #include <private/qdeclarativepropertychanges_p.h> #include <private/qdeclarativestategroup_p.h> #include <private/qdeclarativeitem_p.h> @@ -1126,15 +1125,15 @@ void tst_qdeclarativestates::reset() QDeclarativeRectangle *rect = qobject_cast<QDeclarativeRectangle*>(c.create()); QVERIFY(rect != 0); - QDeclarativeText *text = rect->findChild<QDeclarativeText*>(); - QVERIFY(text != 0); - QCOMPARE(text->width(), qreal(40.)); - QVERIFY(text->width() < text->height()); + QDeclarativeImage *image = rect->findChild<QDeclarativeImage*>(); + QVERIFY(image != 0); + QCOMPARE(image->width(), qreal(40.)); + QCOMPARE(image->height(), qreal(20.)); QDeclarativeItemPrivate::get(rect)->setState("state1"); - QVERIFY(text->width() > 41); - QVERIFY(text->width() > text->height()); + QCOMPARE(image->width(), 20.0); + QCOMPARE(image->height(), qreal(20.)); } void tst_qdeclarativestates::illegalObjectCreation() |