Loading core/java/android/widget/OverScroller.java +6 −23 Original line number Diff line number Diff line Loading @@ -232,11 +232,8 @@ public class OverScroller { * * @return The duration of the scroll in milliseconds. * * @hide Pending removal once nothing depends on it * @deprecated OverScrollers don't necessarily have a fixed duration. * This function will lie to the best of its ability. * @hide */ @Deprecated public final int getDuration() { return Math.max(mScrollerX.mDuration, mScrollerY.mDuration); } Loading @@ -249,13 +246,8 @@ public class OverScroller { * @see #setFinalX(int) * @see #setFinalY(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScrollers don't necessarily have a fixed duration. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated @UnsupportedAppUsage public void extendDuration(int extend) { mScrollerX.extendDuration(extend); Loading @@ -269,13 +261,8 @@ public class OverScroller { * @see #extendDuration(int) * @see #setFinalY(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScroller's final position may change during an animation. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated public void setFinalX(int newX) { mScrollerX.setFinalPosition(newX); } Loading @@ -287,13 +274,8 @@ public class OverScroller { * @see #extendDuration(int) * @see #setFinalX(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScroller's final position may change during an animation. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated public void setFinalY(int newY) { mScrollerY.setFinalPosition(newY); } Loading Loading @@ -710,13 +692,14 @@ public class OverScroller { void setFinalPosition(int position) { mFinal = position; mSplineDistance = mFinal - mStart; mFinished = false; } void extendDuration(int extend) { final long time = AnimationUtils.currentAnimationTimeMillis(); final int elapsedTime = (int) (time - mStartTime); mDuration = elapsedTime + extend; mDuration = mSplineDuration = elapsedTime + extend; mFinished = false; } Loading Loading
core/java/android/widget/OverScroller.java +6 −23 Original line number Diff line number Diff line Loading @@ -232,11 +232,8 @@ public class OverScroller { * * @return The duration of the scroll in milliseconds. * * @hide Pending removal once nothing depends on it * @deprecated OverScrollers don't necessarily have a fixed duration. * This function will lie to the best of its ability. * @hide */ @Deprecated public final int getDuration() { return Math.max(mScrollerX.mDuration, mScrollerY.mDuration); } Loading @@ -249,13 +246,8 @@ public class OverScroller { * @see #setFinalX(int) * @see #setFinalY(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScrollers don't necessarily have a fixed duration. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated @UnsupportedAppUsage public void extendDuration(int extend) { mScrollerX.extendDuration(extend); Loading @@ -269,13 +261,8 @@ public class OverScroller { * @see #extendDuration(int) * @see #setFinalY(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScroller's final position may change during an animation. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated public void setFinalX(int newX) { mScrollerX.setFinalPosition(newX); } Loading @@ -287,13 +274,8 @@ public class OverScroller { * @see #extendDuration(int) * @see #setFinalX(int) * * @hide Pending removal once nothing depends on it * @deprecated OverScroller's final position may change during an animation. * Instead of setting a new final position and extending * the duration of an existing scroll, use startScroll * to begin a new animation. * @hide */ @Deprecated public void setFinalY(int newY) { mScrollerY.setFinalPosition(newY); } Loading Loading @@ -710,13 +692,14 @@ public class OverScroller { void setFinalPosition(int position) { mFinal = position; mSplineDistance = mFinal - mStart; mFinished = false; } void extendDuration(int extend) { final long time = AnimationUtils.currentAnimationTimeMillis(); final int elapsedTime = (int) (time - mStartTime); mDuration = elapsedTime + extend; mDuration = mSplineDuration = elapsedTime + extend; mFinished = false; } Loading