mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 18:58:19 +00:00
Merge "Allowing ability to pick up items / enter overview before full page settle" into jb-ub-now-jolly-elf
This commit is contained in:
@@ -153,7 +153,6 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
|
||||
|
||||
protected int mTouchState = TOUCH_STATE_REST;
|
||||
protected boolean mForceScreenScrolled = false;
|
||||
private boolean mScrollAbortedFromIntercept = false;
|
||||
|
||||
|
||||
protected OnLongClickListener mLongClickListener;
|
||||
@@ -1395,13 +1394,13 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
|
||||
* being flinged.
|
||||
*/
|
||||
final int xDist = Math.abs(mScroller.getFinalX() - mScroller.getCurrX());
|
||||
final boolean finishedScrolling = (mScroller.isFinished() || xDist < mTouchSlop);
|
||||
final boolean finishedScrolling = (mScroller.isFinished() || xDist < mTouchSlop / 3);
|
||||
|
||||
if (finishedScrolling) {
|
||||
mTouchState = TOUCH_STATE_REST;
|
||||
if (!mScroller.isFinished()) {
|
||||
mScrollAbortedFromIntercept = true;
|
||||
abortScrollerAnimation(false);
|
||||
setCurrentPage(getNextPage());
|
||||
pageEndMoving();
|
||||
}
|
||||
} else {
|
||||
if (isTouchPointInViewportWithBuffer((int) mDownMotionX, (int) mDownMotionY)) {
|
||||
@@ -1429,9 +1428,6 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
|
||||
|
||||
case MotionEvent.ACTION_UP:
|
||||
case MotionEvent.ACTION_CANCEL:
|
||||
if (mScrollAbortedFromIntercept) {
|
||||
snapToDestination();
|
||||
}
|
||||
resetTouchState();
|
||||
break;
|
||||
|
||||
@@ -2000,7 +1996,6 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc
|
||||
releaseVelocityTracker();
|
||||
endReordering();
|
||||
mCancelTap = false;
|
||||
mScrollAbortedFromIntercept = false;
|
||||
mTouchState = TOUCH_STATE_REST;
|
||||
mActivePointerId = INVALID_POINTER;
|
||||
}
|
||||
|
||||
@@ -2114,7 +2114,6 @@ public class Workspace extends SmoothPagedView
|
||||
enableFreeScroll();
|
||||
}
|
||||
|
||||
|
||||
if (state != State.NORMAL) {
|
||||
if (stateIsSpringLoaded) {
|
||||
mNewScale = mSpringLoadedShrinkFactor;
|
||||
|
||||
Reference in New Issue
Block a user