tests/auto/declarative/qmlvisual/animation/pauseAnimation/pauseAnimation-visual.qml
equal
deleted
inserted
replaced
|
1 import Qt 4.7 |
|
2 |
|
3 /* |
|
4 This test shows a bouncing logo. |
|
5 When the test starts the logo should be resting at the bottom. It should immediately move |
|
6 to the top, and then fall down to bounce at the bottom. There should be a pause, and then |
|
7 one repeat of the sequence. |
|
8 */ |
|
9 |
|
10 Rectangle { |
|
11 id: rect |
|
12 width: 120 |
|
13 height: 200 |
|
14 color: "white" |
|
15 Image { |
|
16 id: img |
|
17 source: "pics/qtlogo.png" |
|
18 x: 60-width/2 |
|
19 y: 200-img.height |
|
20 SequentialAnimation on y { |
|
21 loops: Animation.Infinite |
|
22 NumberAnimation { |
|
23 to: 0; duration: 500 |
|
24 easing.type: "InOutQuad" |
|
25 } |
|
26 NumberAnimation { |
|
27 to: 200-img.height |
|
28 easing.type: "OutBounce" |
|
29 duration: 2000 |
|
30 } |
|
31 PauseAnimation { |
|
32 duration: 1000 |
|
33 } |
|
34 } |
|
35 } |
|
36 } |