summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativeecmascript/data/aliasBindingsOverrideTarget.2.qml
blob: 4f07cbf616a78553cb0959ed6ab2525ee1d670c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import QtQuick 1.0

Item {
    id: me
    property bool test: false

    property int value: 9

    AliasBindingsOverrideTargetType {
        id: aliasType
        pointAliasProperty.x: me.value
    }

    Component.onCompleted: {
        if (aliasType.pointAliasProperty.x != 9) return;

        me.value = 11;
        if (aliasType.pointAliasProperty.x != 11) return;

        aliasType.data = 8;
        if (aliasType.pointAliasProperty.x != 11) return;

        me.value = 4;
        if (aliasType.pointAliasProperty.x != 4) return;

        test = true;
    }
}