on xenial help sign in
Tweak launcher animation
ee22bb3Daniel d'Andrada
qml/Launcher/Launcher.qml+3−3
@@ -210,7 +210,7 @@ Item {
210 bottom: parent.bottom
210 bottom: parent.bottom
211 }
211 }
212 x: -width
212 x: -width
213− visible: root.x > 0 || x > -width
213+ visible: root.x > 0 || x > -width || dragArea.pressed
214 model: LauncherModel
214 model: LauncherModel
215
215
216 property bool animate: true
216 property bool animate: true
@@ -283,11 +283,11 @@ Item {
283 width: root.dragAreaWidth
283 width: root.dragAreaWidth
284 height: root.height
284 height: root.height
285
285
286− onTouchXChanged: {
286+ onDistanceChanged: {
287 if (!dragging || launcher.state == "visible")
287 if (!dragging || launcher.state == "visible")
288 return;
288 return;
289
289
290− panel.x = Math.min(0, touchX - panel.width) - root.x
290+ panel.x = -panel.width + Math.min(Math.max(0, distance), panel.width);
291 }
291 }
292
292
293 onDraggingChanged: {
293 onDraggingChanged: {