on xenial help sign in
some more minor fixes
a6eaa8cMichael Zanetti
qml/Stages/TransformedSpreadDelegate.qml+4−3
@@ -26,7 +26,9 @@ SpreadDelegate {
26 property bool selected: false
26 property bool selected: false
27 property bool otherSelected: false
27 property bool otherSelected: false
28
28
29+ // The progress animates the tiles. A value > 0 makes it appear from the right edge. At 1 it reaches the end position.
29 property real progress: 0
30 property real progress: 0
31+ // This is required to snap tile 1 during phase 1 and 2.
30 property real animatedProgress: 0
32 property real animatedProgress: 0
31
33
32 property real startAngle: 0
34 property real startAngle: 0
@@ -89,7 +91,7 @@ SpreadDelegate {
89 property real selectedTopMarginProgress
91 property real selectedTopMarginProgress
90
92
91 // Those values are needed as target values for the end of phase 1.
93 // Those values are needed as target values for the end of phase 1.
92− // As they are static values, lets caluclate them once when entering phase 1 instead of calculating them in each animation pass.
94+ // As they are static values, lets calculate them once when entering phase 1 instead of calculating them in each animation pass.
93 property real phase2startTranslate
95 property real phase2startTranslate
94 property real phase2startAngle
96 property real phase2startAngle
95 property real phase2startScale
97 property real phase2startScale
@@ -102,7 +104,6 @@ SpreadDelegate {
102 selectedScale = scale;
104 selectedScale = scale;
103 selectedOpacity = opacity;
105 selectedOpacity = opacity;
104 selectedTopMarginProgress = topMarginProgress;
106 selectedTopMarginProgress = topMarginProgress;
105− if (index == 1) print("snapshotting values:", selectedProgress, selectedXTranslate, selectedAngle, selectedScale, selectedOpacity, selectedTopMarginProgress)
106 }
107 }
107
108
108 // This calculates how much negative progress there can be if unwinding the spread completely
109 // This calculates how much negative progress there can be if unwinding the spread completely
@@ -228,7 +229,7 @@ SpreadDelegate {
228 case 0:
229 case 0:
229 if (spreadView.phase == 0) {
230 if (spreadView.phase == 0) {
230 return 1;
231 return 1;
231− } else if(spreadView.phase == 1) {
232+ } else if (spreadView.phase == 1) {
232 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4,
233 return linearAnimation(spreadView.positionMarker2, spreadView.positionMarker4,
233 1, phase2startScale, root.progress);
234 1, phase2startScale, root.progress);
234 }
235 }