easier to lock

This commit is contained in:
Marco Martin 2015-06-15 19:28:22 -07:00
parent fbcf4fa457
commit b405f43ed3

View file

@ -395,9 +395,17 @@ MouseEventListener {
} }
//manage separately the first page, the lockscreen //manage separately the first page, the lockscreen
if (contentY < -headerItem.height + root.height && //scrolling down
if (verticalVelocity > 0 && contentY < -headerItem.height + root.height &&
contentY > (-headerItem.height + root.height/6)) { contentY > (-headerItem.height + root.height/6)) {
scrollAnim.to = -root.height scrollAnim.to = -plasmoid.availableScreenRect.height
scrollAnim.running = true;
return;
//scrolling up
} else if (verticalVelocity < 0 && contentY < -headerItem.height + root.height &&
contentY < (-headerItem.height + root.height/6)) {
scrollAnim.to = -headerItem.height;
scrollAnim.running = true; scrollAnim.running = true;
return; return;
} }