aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qsgfocusscope/data/test2.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/qsgfocusscope/data/test2.qml')
-rw-r--r--tests/auto/declarative/qsgfocusscope/data/test2.qml39
1 files changed, 39 insertions, 0 deletions
diff --git a/tests/auto/declarative/qsgfocusscope/data/test2.qml b/tests/auto/declarative/qsgfocusscope/data/test2.qml
new file mode 100644
index 0000000000..ad74f3e9f4
--- /dev/null
+++ b/tests/auto/declarative/qsgfocusscope/data/test2.qml
@@ -0,0 +1,39 @@
+import QtQuick 2.0
+
+Rectangle {
+ color: "white"
+ width: 800
+ height: 600
+
+ Text { text: "All five rectangles should be red" }
+
+ FocusScope {
+ y: 100
+ focus: true; objectName: "item1"
+ Rectangle { width: 50; height: 50; color: parent.activeFocus?"red":"blue" }
+
+ FocusScope {
+ y: 100
+ focus: true; objectName: "item2"
+ Rectangle { width: 50; height: 50; color: parent.activeFocus?"red":"blue" }
+
+ FocusScope {
+ y: 100
+ focus: true; objectName: "item3"
+ Rectangle { width: 50; height: 50; color: parent.activeFocus?"red":"blue" }
+
+ FocusScope {
+ y: 100
+ focus: true; objectName: "item4"
+ Rectangle { width: 50; height: 50; color: parent.activeFocus?"red":"blue" }
+
+ FocusScope {
+ y: 100
+ focus: true; objectName: "item5"
+ Rectangle { width: 50; height: 50; color: parent.activeFocus?"red":"blue" }
+ }
+ }
+ }
+ }
+ }
+}