am 78cb7cf7: Allow animations to run past cancelled draws, if the view is visible.

* commit '78cb7cf7d1d82834c4405650a17e387370004570':
  Allow animations to run past cancelled draws, if the view is visible.
This commit is contained in:
Chris Wren
2012-05-15 11:32:53 -07:00
committed by Android Git Automerger

View File

@@ -1855,18 +1855,15 @@ public final class ViewRootImpl implements ViewParent,
performDraw();
}
} else {
// End any pending transitions on this non-visible window
if (mPendingTransitions != null && mPendingTransitions.size() > 0) {
if (viewVisibility == View.VISIBLE) {
// Try again
scheduleTraversals();
} else if (mPendingTransitions != null && mPendingTransitions.size() > 0) {
for (int i = 0; i < mPendingTransitions.size(); ++i) {
mPendingTransitions.get(i).endChangingAnimations();
}
mPendingTransitions.clear();
}
if (viewVisibility == View.VISIBLE) {
// Try again
scheduleTraversals();
}
}
}