-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGift.qml
67 lines (63 loc) · 1.62 KB
/
Gift.qml
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
import QtQuick 1.0
Image {
id: rootGift;
fillMode: Image.PreserveAspectFit;
property variant validStates: ["fast", "slow", "curse", "extra_ball", "extra_gift", "sticky", "weapon"];
state: "setting up";
states: [
State {
name: "fast"
PropertyChanges {
target: rootGift;
source: "pics/gift_fast.png";
}
},
State {
name: "slow"
PropertyChanges {
target: rootGift;
source: "pics/gift_slow.png";
}
},
State {
name: "curse"
PropertyChanges {
target: rootGift;
source: "pics/gift_curse.png";
}
},
State {
name: "extra_ball"
PropertyChanges {
target: rootGift;
source: "pics/gift_ball.png";
}
},
State {
name: "extra_gift"
PropertyChanges {
target: rootGift;
source: "pics/gift_live.png";
}
},
State {
name: "sticky"
PropertyChanges {
target: rootGift;
source: "pics/gift_sticky.png";
}
},
State {
name: "weapon"
PropertyChanges {
target: rootGift;
source: "pics/gift_weapon.png";
}
}
]
Behavior on y {
enabled: state != "setting up";
NumberAnimation { duration: 50; }
}
Component.onCompleted: { state: "setting up" }
}