aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qqmlecmascript/data/switchStatement.6.qml
blob: 6fb71eb34597101d92631645726fee7fed7066af (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
import Qt.test 1.0

MyQmlObject {
    function one(kind) { return 123 }
    function two(kind) { return 321 }

    value: switch (stringProperty) {
               case "A": case "S": one(stringProperty); break;
               case "D": case "F": two(stringProperty); break;
               default: 0
           }
}