on xenial help sign in
prevent tile 0 from moving to the right.
9f8afb7Michael Zanetti
qml/Stages/TransformedSpreadDelegate.qml+2−2
@@ -116,7 +116,7 @@ SpreadDelegate {
116 switch (index) {
116 switch (index) {
117 case 0:
117 case 0:
118 if (spreadView.stage == 0) {
118 if (spreadView.stage == 0) {
119− return linearAnimation(0, spreadView.positionMarker2, 0, -spreadView.width * .25, root.animatedProgress)
119+ return Math.min(0, linearAnimation(0, spreadView.positionMarker2, 0, -spreadView.width * .25, root.animatedProgress))
120 } else if (spreadView.stage == 1){
120 } else if (spreadView.stage == 1){
121 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4, -spreadView.width * .25, priv.stage2startTranslate, root.progress)
121 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4, -spreadView.width * .25, priv.stage2startTranslate, root.progress)
122 } else if (!priv.isSelected){ // Stage 2
122 } else if (!priv.isSelected){ // Stage 2
@@ -158,7 +158,7 @@ SpreadDelegate {
158 switch (index) {
158 switch (index) {
159 case 0:
159 case 0:
160 if (spreadView.stage == 0) {
160 if (spreadView.stage == 0) {
161− return linearAnimation(0, spreadView.positionMarker2, 0, root.tile0SnapAngle, root.animatedProgress)
161+ return Math.max(0, linearAnimation(0, spreadView.positionMarker2, 0, root.tile0SnapAngle, root.animatedProgress))
162 } else if (spreadView.stage == 1) {
162 } else if (spreadView.stage == 1) {
163 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4, root.tile0SnapAngle, stage2startAngle, root.progress)
163 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4, root.tile0SnapAngle, stage2startAngle, root.progress)
164 }
164 }