Initial import from the monolithic Qt.
[profile/ivi/qtdeclarative.git] / tests / auto / declarative / qdeclarativeanimations / data / mixedtype1.qml
1 import QtQuick 1.0
2
3 Rectangle {
4     id: wrapper
5     width: 240
6     height: 320
7     Rectangle {
8         id: myRect
9         objectName: "MyRect"
10         color: "red"
11         width: 50; height: 50
12         x: 100; y: 100
13         MouseArea {
14             anchors.fill: parent
15             onClicked: if (wrapper.state == "state1") wrapper.state = ""; else wrapper.state = "state1";
16         }
17     }
18     states: State {
19         name: "state1"
20         PropertyChanges { target: myRect; x: 200; border.width: 10 }
21     }
22     transitions: Transition {
23         PropertyAnimation { properties: "x,border.width"; duration: 1000 } //x is real, border.width is int
24     }
25 }