Merge "Prevent infinite loop in the Phone UI."

This commit is contained in:
Romain Guy
2010-02-10 11:30:03 -08:00
committed by Android (Google) Code Review

View File

@@ -281,8 +281,8 @@ public abstract class Animation implements Cloneable {
*/
public void detach() {
if (mStarted && !mEnded) {
if (mListener != null) mListener.onAnimationEnd(this);
mEnded = true;
if (mListener != null) mListener.onAnimationEnd(this);
}
}
@@ -776,10 +776,10 @@ public abstract class Animation implements Cloneable {
if (expired) {
if (mRepeatCount == mRepeated) {
if (!mEnded) {
mEnded = true;
if (mListener != null) {
mListener.onAnimationEnd(this);
}
mEnded = true;
}
} else {
if (mRepeatCount > 0) {