summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMartin Jones <martin.jones@nokia.com>2010-07-22 03:57:46 (GMT)
committerMartin Jones <martin.jones@nokia.com>2010-07-22 03:57:46 (GMT)
commit5dd0dfcd7a079065f99c6149c15b58e69f302729 (patch)
treebf9bf2f202cdf5fdd5d4b52931036c8bc458569c /tests
parent91215b48022b3b3980960f1b5f301ac84f14d49d (diff)
downloadQt-5dd0dfcd7a079065f99c6149c15b58e69f302729.zip
Qt-5dd0dfcd7a079065f99c6149c15b58e69f302729.tar.gz
Qt-5dd0dfcd7a079065f99c6149c15b58e69f302729.tar.bz2
Allow MouseArea dragging to filter mouse events from descendants
This allows dragging a MouseArea that contains a clickable MouseArea, for example. Task-number: QTBUG-12323 Reviewed-by: Michael Brasser
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative/qdeclarativemousearea/tst_qdeclarativemousearea.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativemousearea/tst_qdeclarativemousearea.cpp b/tests/auto/declarative/qdeclarativemousearea/tst_qdeclarativemousearea.cpp
index 5a10372..c9bb467 100644
--- a/tests/auto/declarative/qdeclarativemousearea/tst_qdeclarativemousearea.cpp
+++ b/tests/auto/declarative/qdeclarativemousearea/tst_qdeclarativemousearea.cpp
@@ -137,6 +137,17 @@ void tst_QDeclarativeMouseArea::dragProperties()
QCOMPARE(yminSpy.count(),1);
QCOMPARE(ymaxSpy.count(),1);
+ // filterChildren
+ QSignalSpy filterChildrenSpy(drag, SIGNAL(filterChildrenChanged()));
+
+ drag->setFilterChildren(true);
+
+ QVERIFY(drag->filterChildren());
+ QCOMPARE(filterChildrenSpy.count(), 1);
+
+ drag->setFilterChildren(true);
+ QCOMPARE(filterChildrenSpy.count(), 1);
+
delete canvas;
}