summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/layouts/tst_layouts.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/layouts/tst_layouts.cpp')
-rw-r--r--tests/auto/declarative/layouts/tst_layouts.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/auto/declarative/layouts/tst_layouts.cpp b/tests/auto/declarative/layouts/tst_layouts.cpp
index 53c1ede..b580336 100644
--- a/tests/auto/declarative/layouts/tst_layouts.cpp
+++ b/tests/auto/declarative/layouts/tst_layouts.cpp
@@ -40,9 +40,9 @@
****************************************************************************/
#include <QtTest/QtTest>
#include <private/qlistmodelinterface_p.h>
-#include <qmlview.h>
-#include <private/qmlgraphicslayoutitem_p.h>
-#include <qmlexpression.h>
+#include <qdeclarativeview.h>
+#include <private/qdeclarativelayoutitem_p.h>
+#include <qdeclarativeexpression.h>
#include <QStyle>
class tst_QmlGraphicsLayouts : public QObject
@@ -56,7 +56,7 @@ private slots:
void test_cpp();//GraphicsLayout set up in C++
private:
- QmlView *createView(const QString &filename);
+ QDeclarativeView *createView(const QString &filename);
};
tst_QmlGraphicsLayouts::tst_QmlGraphicsLayouts()
@@ -65,13 +65,13 @@ tst_QmlGraphicsLayouts::tst_QmlGraphicsLayouts()
void tst_QmlGraphicsLayouts::test_qml()
{
- QmlView *canvas = createView(SRCDIR "/data/layouts.qml");
+ QDeclarativeView *canvas = createView(SRCDIR "/data/layouts.qml");
qApp->processEvents();
- QmlGraphicsLayoutItem *left = static_cast<QmlGraphicsLayoutItem*>(canvas->rootObject()->findChild<QmlGraphicsItem*>("left"));
+ QDeclarativeLayoutItem *left = static_cast<QDeclarativeLayoutItem*>(canvas->rootObject()->findChild<QDeclarativeItem*>("left"));
QVERIFY(left != 0);
- QmlGraphicsLayoutItem *right = static_cast<QmlGraphicsLayoutItem*>(canvas->rootObject()->findChild<QmlGraphicsItem*>("right"));
+ QDeclarativeLayoutItem *right = static_cast<QDeclarativeLayoutItem*>(canvas->rootObject()->findChild<QDeclarativeItem*>("right"));
QVERIFY(right != 0);
qreal l = QApplication::style()->pixelMetric(QStyle::PM_LayoutLeftMargin);
@@ -81,7 +81,7 @@ void tst_QmlGraphicsLayouts::test_qml()
QVERIFY2(l == r && r == t && t == b, "Test assumes equal margins.");
qreal gvMargin = l;
- QmlGraphicsItem *rootItem = qobject_cast<QmlGraphicsItem*>(canvas->rootObject());
+ QDeclarativeItem *rootItem = qobject_cast<QDeclarativeItem*>(canvas->rootObject());
QVERIFY(rootItem != 0);
//Preferred Size
@@ -133,9 +133,9 @@ void tst_QmlGraphicsLayouts::test_cpp()
//TODO: Waiting on QT-2407 to write this test
}
-QmlView *tst_QmlGraphicsLayouts::createView(const QString &filename)
+QDeclarativeView *tst_QmlGraphicsLayouts::createView(const QString &filename)
{
- QmlView *canvas = new QmlView(0);
+ QDeclarativeView *canvas = new QDeclarativeView(0);
canvas->setSource(QUrl::fromLocalFile(filename));
return canvas;