diff options
| -rw-r--r-- | services/core/java/com/android/server/wm/WindowState.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java index e9aff88d0f80..234900e36245 100644 --- a/services/core/java/com/android/server/wm/WindowState.java +++ b/services/core/java/com/android/server/wm/WindowState.java @@ -1784,7 +1784,11 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP final ActivityRecord atoken = mActivityRecord; return mViewVisibility == View.GONE || !mRelayoutCalled - || (atoken == null && !mToken.isVisible()) + // We can't check isVisible here because it will also check the client visibility + // for WindowTokens. Even if the client is not visible, we still need to perform + // a layout since they can request relayout when client visibility is false. + // TODO (b/157682066) investigate if we can clean up isVisible + || (atoken == null && !(wouldBeVisibleIfPolicyIgnored() && isVisibleByPolicy())) || (atoken != null && !atoken.mVisibleRequested) || isParentWindowGoneForLayout() || (mAnimatingExit && !isAnimatingLw()) |