on xenial help sign in
make a bunch of properties readonly
commitb2495d56870c670d38727a0635c8297ce67a5d2e authorMichael Zanetti <michael.zanetti@canonical.com> dateFri 18 Jul 2014, 18:54 (12 years ago) parentbaae18a
1 file changed+9−9
qml/Stages/TabletStage.qml+9−9
qml/Stages/TabletStage.qml+9−9
@@ -137,22 +137,22 @@ Item {
137137 // 2: The list is dragged further and snaps into the spread view when entering phase 2
138138 property int phase
139139
140− property int phase0Width: sideStageWidth
141− property int phase1Width: sideStageWidth
140+ readonly property int phase0Width: sideStageWidth
141+ readonly property int phase1Width: sideStageWidth
142142
143143 // Those markers mark the various positions in the spread (ratio to screen width from right to left):
144144 // 0 - 1: following finger, snap back to the beginning on release
145− property real positionMarker1: 0.2
145+ readonly property real positionMarker1: 0.2
146146 // 1 - 2: curved snapping movement, snap to nextInStack on release
147− property real positionMarker2: sideStageWidth / spreadView.width
147+ readonly property real positionMarker2: sideStageWidth / spreadView.width
148148 // 2 - 3: movement follows finger, snaps to phase 2 (full spread) on release
149− property real positionMarker3: 0.6
149+ readonly property real positionMarker3: 0.6
150150 // passing 3, we detach movement from the finger and snap to phase 2 (full spread)
151− property real positionMarker4: 0.8
151+ readonly property real positionMarker4: 0.8
152152
153− property int startSnapPosition: phase0Width * 0.5
154− property int endSnapPosition: phase0Width * 0.75
155− property real snapPosition: 0.75
153+ readonly property int startSnapPosition: phase0Width * 0.5
154+ readonly property int endSnapPosition: phase0Width * 0.75
155+ readonly property real snapPosition: 0.75
156156
157157 property int selectedIndex: -1
158158 property int draggedIndex: -1