Loading src/com/android/launcher3/PagedView.java +5 −1 Original line number Diff line number Diff line Loading @@ -1599,7 +1599,7 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc mTotalMotionX += Math.abs(mLastMotionX + mLastMotionXRemainder - x); boolean isFling = mTotalMotionX > MIN_LENGTH_FOR_FLING && Math.abs(velocityX) > mFlingThresholdVelocity; shouldFlingForVelocity(velocityX); if (!mFreeScroll) { // In the case that the page is moved far to one direction and then is flung Loading Loading @@ -1705,6 +1705,10 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc return true; } protected boolean shouldFlingForVelocity(int velocityX) { return Math.abs(velocityX) > mFlingThresholdVelocity; } private void resetTouchState() { releaseVelocityTracker(); endReordering(); Loading src/com/android/launcher3/Workspace.java +7 −0 Original line number Diff line number Diff line Loading @@ -1462,6 +1462,13 @@ public class Workspace extends PagedView } } @Override protected boolean shouldFlingForVelocity(int velocityX) { // When the overlay is moving, the fling or settle transition is controlled by the overlay. return Float.compare(mOverlayTranslation, 0) == 0 && super.shouldFlingForVelocity(velocityX); } private final Interpolator mAlphaInterpolator = new DecelerateInterpolator(3f); /** Loading Loading
src/com/android/launcher3/PagedView.java +5 −1 Original line number Diff line number Diff line Loading @@ -1599,7 +1599,7 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc mTotalMotionX += Math.abs(mLastMotionX + mLastMotionXRemainder - x); boolean isFling = mTotalMotionX > MIN_LENGTH_FOR_FLING && Math.abs(velocityX) > mFlingThresholdVelocity; shouldFlingForVelocity(velocityX); if (!mFreeScroll) { // In the case that the page is moved far to one direction and then is flung Loading Loading @@ -1705,6 +1705,10 @@ public abstract class PagedView extends ViewGroup implements ViewGroup.OnHierarc return true; } protected boolean shouldFlingForVelocity(int velocityX) { return Math.abs(velocityX) > mFlingThresholdVelocity; } private void resetTouchState() { releaseVelocityTracker(); endReordering(); Loading
src/com/android/launcher3/Workspace.java +7 −0 Original line number Diff line number Diff line Loading @@ -1462,6 +1462,13 @@ public class Workspace extends PagedView } } @Override protected boolean shouldFlingForVelocity(int velocityX) { // When the overlay is moving, the fling or settle transition is controlled by the overlay. return Float.compare(mOverlayTranslation, 0) == 0 && super.shouldFlingForVelocity(velocityX); } private final Interpolator mAlphaInterpolator = new DecelerateInterpolator(3f); /** Loading