Skip to content

Commit 0c348b6

Browse files
chethaaseAndroid (Google) Code Review
authored andcommitted
Merge "end() a reverse()'d animation correctly" into jb-mr1-dev
2 parents 51e67a0 + 4dd1768 commit 0c348b6

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

core/java/android/animation/ValueAnimator.java

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -958,13 +958,7 @@ public void end() {
958958
} else if (!mInitialized) {
959959
initAnimation();
960960
}
961-
// The final value set on the target varies, depending on whether the animation
962-
// was supposed to repeat an odd number of times
963-
if (mRepeatCount > 0 && (mRepeatCount & 0x01) == 1) {
964-
animateValue(0f);
965-
} else {
966-
animateValue(1f);
967-
}
961+
animateValue(mPlayingBackwards ? 0f : 1f);
968962
endAnimation(handler);
969963
}
970964

0 commit comments

Comments
 (0)