Fix calculation of showProgress
commit578fb496281ab9947cef170cbf90d44b84cc21ba
authorMichael Terry <michael.terry@canonical.com>
dateThu 27 Mar 2014, 17:14 (13 years ago)
parent1268c36
qml/Greeter/Greeter.qml+1−1
@@ -28,7 +28,7 @@ Showable {
2828 property url defaultBackground
2929
3030 // 1 when fully shown and 0 when fully hidden
31− property real showProgress: MathUtils.clamp((width + x) / width, 0, 1)
31+ property real showProgress: MathUtils.clamp((width - Math.abs(x)) / width, 0, 1)
3232
3333 showAnimation: StandardAnimation { property: "x"; to: 0 }
3434 hideAnimation: __leftHideAnimation