Merge "Skip sync invisible & lifecycle-unlreated window for an Activity." into udc-qpr-dev am: 7786667ad2 am: f6d2c1d7ec

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/24175731

Change-Id: I398ac1c3bd331648d90334eeac17d11495724c0b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Wei Sheng Shih
2023-08-02 03:38:24 +00:00
committed by Automerger Merge Worker

View File

@@ -5682,6 +5682,12 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP
// TODO(b/233286785): Add sync support to wallpaper.
return true;
}
if (mActivityRecord != null && mViewVisibility != View.VISIBLE
&& mWinAnimator.mAttrType != TYPE_BASE_APPLICATION
&& mWinAnimator.mAttrType != TYPE_APPLICATION_STARTING) {
// Skip sync for invisible app windows which are not managed by activity lifecycle.
return false;
}
// In the WindowContainer implementation we immediately mark ready
// since a generic WindowContainer only needs to wait for its
// children to finish and is immediately ready from its own