~saviq/ubuntu/saucy/qtdeclarative-opensource-src/add-qtquick-delegate-range

« back to all changes in this revision

Viewing changes to tests/auto/quick/qquickanimations/data/propertiesTransition2.qml

  • Committer: Package Import Robot
  • Author(s): Timo Jyrinki
  • Date: 2013-02-05 14:17:19 UTC
  • Revision ID: package-import@ubuntu.com-20130205141719-qqeyml8wslpyez52
Tags: upstream-5.0.1
ImportĀ upstreamĀ versionĀ 5.0.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
import QtQuick 2.0
 
2
 
 
3
Rectangle {
 
4
    width: 400
 
5
    height: 400
 
6
    Rectangle {
 
7
        id: theRect
 
8
        objectName: "TheRect"
 
9
        color: "red"
 
10
        width: 50; height: 50
 
11
        x: 100; y: 100
 
12
    }
 
13
 
 
14
    states: State {
 
15
        name: "moved"
 
16
        PropertyChanges {
 
17
            target: theRect
 
18
            x: 200
 
19
        }
 
20
    }
 
21
    transitions: Transition {
 
22
        NumberAnimation { target: theRect; property: "y"; to: 200 }
 
23
    }
 
24
 
 
25
    MouseArea {
 
26
        anchors.fill: parent
 
27
        onClicked: parent.state = "moved"
 
28
    }
 
29
}