diff options
| -rw-r--r-- | core/java/android/animation/ObjectAnimator.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/java/android/animation/ObjectAnimator.java b/core/java/android/animation/ObjectAnimator.java index 9a2aa302a4ba..0c21c4ff55e7 100644 --- a/core/java/android/animation/ObjectAnimator.java +++ b/core/java/android/animation/ObjectAnimator.java @@ -977,8 +977,9 @@ public final class ObjectAnimator extends ValueAnimator { @Override void animateValue(float fraction) { final Object target = getTarget(); - if (target == null) { - // We lost the target reference, cancel and clean up. + if (mTarget != null && target == null) { + // We lost the target reference, cancel and clean up. Note: we allow null target if the + /// target has never been set. cancel(); return; } |