summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-06-03 19:27:37 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-06-03 19:27:37 (GMT)
commitf6d3753892353e6064fa1fc3c4bf0ba2fad900a6 (patch)
tree2231dfabee6314a5fa1e9d8cab12a7ed8436e254 /tests
parenta66efc054ce9a9b2fc0535a7269f921ea411498c (diff)
parent66410ec9be30b09d6b61554d091c3f9907745787 (diff)
downloadQt-f6d3753892353e6064fa1fc3c4bf0ba2fad900a6.zip
Qt-f6d3753892353e6064fa1fc3c4bf0ba2fad900a6.tar.gz
Qt-f6d3753892353e6064fa1fc3c4bf0ba2fad900a6.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: Add more Q_AUTOTEST_EXPORTs Improve input panel handling in declarative demos and examples Always integer align anchor center points Add header and footer to GridView
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative/qdeclarativegridview/tst_qdeclarativegridview.cpp13
-rw-r--r--tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp6
-rw-r--r--tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp6
3 files changed, 13 insertions, 12 deletions
diff --git a/tests/auto/declarative/qdeclarativegridview/tst_qdeclarativegridview.cpp b/tests/auto/declarative/qdeclarativegridview/tst_qdeclarativegridview.cpp
index 2db3ee6..fb09d39 100644
--- a/tests/auto/declarative/qdeclarativegridview/tst_qdeclarativegridview.cpp
+++ b/tests/auto/declarative/qdeclarativegridview/tst_qdeclarativegridview.cpp
@@ -833,21 +833,34 @@ void tst_QDeclarativeGridView::componentChanges()
QSignalSpy highlightSpy(gridView, SIGNAL(highlightChanged()));
QSignalSpy delegateSpy(gridView, SIGNAL(delegateChanged()));
+ QSignalSpy headerSpy(gridView, SIGNAL(headerChanged()));
+ QSignalSpy footerSpy(gridView, SIGNAL(footerChanged()));
gridView->setHighlight(&component);
gridView->setDelegate(&delegateComponent);
+ gridView->setHeader(&component);
+ gridView->setFooter(&component);
QTRY_COMPARE(gridView->highlight(), &component);
QTRY_COMPARE(gridView->delegate(), &delegateComponent);
+ QTRY_COMPARE(gridView->header(), &component);
+ QTRY_COMPARE(gridView->footer(), &component);
QTRY_COMPARE(highlightSpy.count(),1);
QTRY_COMPARE(delegateSpy.count(),1);
+ QTRY_COMPARE(headerSpy.count(),1);
+ QTRY_COMPARE(footerSpy.count(),1);
gridView->setHighlight(&component);
gridView->setDelegate(&delegateComponent);
+ gridView->setHeader(&component);
+ gridView->setFooter(&component);
QTRY_COMPARE(highlightSpy.count(),1);
QTRY_COMPARE(delegateSpy.count(),1);
+ QTRY_COMPARE(headerSpy.count(),1);
+ QTRY_COMPARE(footerSpy.count(),1);
+
delete canvas;
}
diff --git a/tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp b/tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp
index fbab30e..474eb3f 100644
--- a/tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp
+++ b/tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp
@@ -956,12 +956,6 @@ void tst_qdeclarativetextedit::openInputPanelOnFocus()
edit.setFocusOnPress(true);
QCOMPARE(focusOnPressSpy.count(),2);
- // active window focus reason should not cause input panel to open
- QGraphicsObject * editObject = qobject_cast<QGraphicsObject*>(&edit);
- editObject->setFocus(Qt::ActiveWindowFocusReason);
- QCOMPARE(ic.openInputPanelReceived, false);
- QCOMPARE(ic.closeInputPanelReceived, false);
-
// and input panel should not open if focus has already been set
edit.setFocus(true);
QCOMPARE(ic.openInputPanelReceived, false);
diff --git a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp
index 3cb4da0..c1c6634 100644
--- a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp
+++ b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp
@@ -902,12 +902,6 @@ void tst_qdeclarativetextinput::openInputPanelOnFocus()
input.setFocusOnPress(true);
QCOMPARE(focusOnPressSpy.count(),2);
- // active window focus reason should not cause input panel to open
- QGraphicsObject * inputObject = qobject_cast<QGraphicsObject*>(&input);
- inputObject->setFocus(Qt::ActiveWindowFocusReason);
- QCOMPARE(ic.openInputPanelReceived, false);
- QCOMPARE(ic.closeInputPanelReceived, false);
-
// and input panel should not open if focus has already been set
input.setFocus(true);
QCOMPARE(ic.openInputPanelReceived, false);