summaryrefslogtreecommitdiffstats
path: root/doc/src/declarative
diff options
context:
space:
mode:
authorLeonardo Sobral Cunha <leo.cunha@nokia.com>2010-02-23 03:29:04 (GMT)
committerLeonardo Sobral Cunha <leo.cunha@nokia.com>2010-02-23 08:11:29 (GMT)
commit0a7ca8efdd292f317d4c95a80485d9d51f14a694 (patch)
tree2130504540adc987c7202dabb324f5a58fa9dbeb /doc/src/declarative
parentab2497c20116399e963748adf0ed2bf691d42cbf (diff)
downloadQt-0a7ca8efdd292f317d4c95a80485d9d51f14a694.zip
Qt-0a7ca8efdd292f317d4c95a80485d9d51f14a694.tar.gz
Qt-0a7ca8efdd292f317d4c95a80485d9d51f14a694.tar.bz2
Adds QmlEasingValueType to qml
Now it's possible to use easing curve types directly in qml as value types, {easing.type: "OutBounce"; easing.amplitude: 3}, instead of the former ugly string format, like "easeOutBounce(amplitude:3.0)". Reviewed-by: akennedy
Diffstat (limited to 'doc/src/declarative')
-rw-r--r--doc/src/declarative/animation.qdoc12
1 files changed, 6 insertions, 6 deletions
diff --git a/doc/src/declarative/animation.qdoc b/doc/src/declarative/animation.qdoc
index d80c3fa..892535e 100644
--- a/doc/src/declarative/animation.qdoc
+++ b/doc/src/declarative/animation.qdoc
@@ -72,9 +72,9 @@ Rectangle {
y: 0
y: SequentialAnimation {
repeat: true
- NumberAnimation { to: 200-img.height; easing: "easeOutBounce"; duration: 2000 }
+ NumberAnimation { to: 200-img.height; easing.type: "OutBounce"; duration: 2000 }
PauseAnimation { duration: 1000 }
- NumberAnimation { to: 0; easing: "easeOutQuad"; duration: 1000 }
+ NumberAnimation { to: 0; easing.type: "OutQuad"; duration: 1000 }
}
}
}
@@ -135,7 +135,7 @@ transitions: [
Transition {
NumberAnimation {
properties: "x,y"
- easing: "easeOutBounce"
+ easing.type: "OutBounce"
duration: 200
}
}
@@ -156,7 +156,7 @@ Transition {
SequentialAnimation {
NumberAnimation {
duration: 1000
- easing: "easeOutBounce"
+ easing.type: "OutBounce"
// animate myItem's x and y if they have changed in the state
target: myItem
properties: "x,y"
@@ -198,7 +198,7 @@ Transition {
ParallelAnimation {
NumberAnimation {
duration: 1000
- easing: "easeOutBounce"
+ easing.type: "OutBounce"
targets: box1
properties: "x,y"
}
@@ -226,7 +226,7 @@ Rectangle {
id: redRect
color: "red"
width: 100; height: 100
- x: Behavior { NumberAnimation { duration: 300; easing: "InOutQuad" } }
+ x: Behavior { NumberAnimation { duration: 300; easing.type: "InOutQuad" } }
}
\endqml