Loading core/java/android/animation/Animator.java +6 −1 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.animation; import android.annotation.Nullable; import android.content.pm.ActivityInfo.Config; import android.content.res.ConstantState; Loading Loading @@ -436,10 +437,14 @@ public abstract class Animator implements Cloneable { * operate on target objects (for example, {@link ValueAnimator}, but this method * is on the superclass for the convenience of dealing generically with those subclasses * that do handle targets. * <p> * <strong>Note:</strong> The target is stored as a weak reference internally to avoid leaking * resources by having animators directly reference old targets. Therefore, you should * ensure that animator targets always have a hard reference elsewhere. * * @param target The object being animated */ public void setTarget(Object target) { public void setTarget(@Nullable Object target) { } // Hide reverse() and canReverse() for now since reverse() only work for simple Loading core/java/android/animation/ObjectAnimator.java +0 −6 Original line number Diff line number Diff line Loading @@ -898,12 +898,6 @@ public final class ObjectAnimator extends ValueAnimator { return mTarget == null ? null : mTarget.get(); } /** * Sets the target object whose property will be animated by this animation. If the * animator has been started, it will be canceled. * * @param target The object being animated */ @Override public void setTarget(@Nullable Object target) { final Object oldTarget = getTarget(); Loading Loading
core/java/android/animation/Animator.java +6 −1 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.animation; import android.annotation.Nullable; import android.content.pm.ActivityInfo.Config; import android.content.res.ConstantState; Loading Loading @@ -436,10 +437,14 @@ public abstract class Animator implements Cloneable { * operate on target objects (for example, {@link ValueAnimator}, but this method * is on the superclass for the convenience of dealing generically with those subclasses * that do handle targets. * <p> * <strong>Note:</strong> The target is stored as a weak reference internally to avoid leaking * resources by having animators directly reference old targets. Therefore, you should * ensure that animator targets always have a hard reference elsewhere. * * @param target The object being animated */ public void setTarget(Object target) { public void setTarget(@Nullable Object target) { } // Hide reverse() and canReverse() for now since reverse() only work for simple Loading
core/java/android/animation/ObjectAnimator.java +0 −6 Original line number Diff line number Diff line Loading @@ -898,12 +898,6 @@ public final class ObjectAnimator extends ValueAnimator { return mTarget == null ? null : mTarget.get(); } /** * Sets the target object whose property will be animated by this animation. If the * animator has been started, it will be canceled. * * @param target The object being animated */ @Override public void setTarget(@Nullable Object target) { final Object oldTarget = getTarget(); Loading