Merge "Revert "Accept a Window as shown if it's in any transition"" into udc-dev

This commit is contained in:
Robin Lee
2023-04-27 12:58:34 +00:00
committed by Android (Google) Code Review

View File

@@ -1980,19 +1980,16 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
/**
* Like isOnScreen(), but we don't return true if the window is part
* of a transition but has not yet started animating.
* of a transition that has not yet been started.
*/
boolean isReadyForDisplay() {
if (!mHasSurface || mDestroying || !isVisibleByPolicy()) {
return false;
}
if (mToken.waitingToShow && getDisplayContent().mAppTransition.isTransitionSet()
&& !isAnimating(TRANSITION | PARENTS, ANIMATION_TYPE_APP_TRANSITION)) {
if (mToken.waitingToShow && getDisplayContent().mAppTransition.isTransitionSet()) {
return false;
}
final boolean parentAndClientVisible = !isParentWindowHidden()
&& mViewVisibility == View.VISIBLE && mToken.isVisible();
return parentAndClientVisible || isAnimating(TRANSITION | PARENTS, ANIMATION_TYPE_ALL);
return mHasSurface && isVisibleByPolicy() && !mDestroying
&& (parentAndClientVisible || isAnimating(TRANSITION | PARENTS));
}
boolean isFullyTransparent() {