commit | 174ce16ec59b1ab11b074460c23b0286f7da08eb | [log] [tgz] |
---|---|---|
author | Gabriel Peal <gpeal@users.noreply.github.com> | Sun May 19 16:34:45 2019 -0700 |
committer | GitHub <noreply@github.com> | Sun May 19 16:34:45 2019 -0700 |
tree | e9fa2bcc0b2fd89d1f41d25425c87f0b04615ea1 | |
parent | a143d345a22c49288febb7c999a32962696a3e37 [diff] |
Set correct frame when animation ends and speed is < 0 (#1222) Fixes #1207
diff --git a/lottie/src/main/java/com/airbnb/lottie/utils/LottieValueAnimator.java b/lottie/src/main/java/com/airbnb/lottie/utils/LottieValueAnimator.java index 7898461..7318f55 100644 --- a/lottie/src/main/java/com/airbnb/lottie/utils/LottieValueAnimator.java +++ b/lottie/src/main/java/com/airbnb/lottie/utils/LottieValueAnimator.java
@@ -96,7 +96,7 @@ notifyUpdate(); if (ended) { if (getRepeatCount() != INFINITE && repeatCount >= getRepeatCount()) { - frame = getMaxFrame(); + frame = speed < 0 ? getMinFrame() : getMaxFrame(); removeFrameCallback(); notifyEnd(isReversed()); } else {