Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.3.0 RC1, 5.7.1
-
None
-
44dd79eeda (qt/qtdeclarative/dev) 44dd79eeda (qt/tqtc-qtdeclarative/dev)
Description
Run the following test case and resize the window => the animation is "off". Toggling Animation::running helps to re-evaluate from & to -values, but this makes it very inconvenient to implement for example busy animation for scalable progress bars etc. where the from & to -values are not fixed. It would be better if PropertyAnimation would mark the changed from & to -values as dirty, and update the animation in the beginning of the next loop.
import QtQuick 2.2 MouseArea { id: window width: 300 height: 200 Rectangle { id: background radius: 2 clip: true color: "lightgray" width: parent.width / 3 * 2 height: parent.height / 10 anchors.centerIn: parent Rectangle { id: bar color: "lightsteelblue" border.color: "steelblue" width: parent.width / 2 height: parent.height / 2 anchors.verticalCenter: parent.verticalCenter NumberAnimation on x { id: anim from: -bar.width to: frame.width loops: Animation.Infinite duration: 1000 } } Rectangle { id: frame radius: 2 color: "transparent" border.color: "gray" border.width: 1 anchors.fill: parent } } onClicked: { anim.stop() anim.start() } }
Attachments
Issue Links
- relates to
-
QTBUG-61282 Changing an Animation duration has no effect
-
- Closed
-
-
QTBUG-95840 QML Animations: not specified how they react to property changes while running
-
- Closed
-
-
QTBUG-17552 Changes to Animation's 'to' and 'from' properties ignored while animating
-
- Closed
-
For Gerrit Dashboard: QTBUG-38932 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
405384,8 | Allow modifying from, to, duration and easing properties during animation | dev | qt/qtdeclarative | Status: MERGED | +2 | 0 |