Fix bug where physics appears not to run in all apps.
ie. When scrolling up from the bottom, the animation will immediately start since the last visible item condition is true — and by the time it reaches the top the spring is done moving. Bug: 38349031 Change-Id: I344deef47c50b33405345dd3a137ccdb12aeae02
This commit is contained in:
1 parent
f6add46e5e
commit
75de76f917
2 files changed
+11
-4
No files matched your search
@@ -138,6 +138,11 @@ public class SpringAnimationHandler {
|
||||
reset();
|
||||
}
|
||||
|
||||
public boolean isRunning() {
|
||||
// All the animations run at the same time so we can just check the first one.
|
||||
return !mAnimations.isEmpty() && mAnimations.get(0).isRunning();
|
||||
}
|
||||
|
||||
public void skipToEnd() {
|
||||
if (DEBUG) Log.d(TAG, "setStartVelocity#skipToEnd");
|
||||
if (DEBUG) Log.v(TAG, "setStartVelocity#skipToEnd", new Exception());
|
||||
|
||||
Reference in new issue
Block a user