Merge "Do not capture activity snapshot if starting window is associated to task." into udc-dev

This commit is contained in:
Wei Sheng Shih
2023-07-13 01:47:53 +00:00
committed by Android (Google) Code Review

View File

@@ -712,6 +712,14 @@ class Transition implements BLASTSyncEngine.TransactionReadyListener {
mFlags |= WindowManager.TRANSIT_FLAG_INVISIBLE;
return;
}
// Activity doesn't need to capture snapshot if the starting window has associated to task.
if (wc.asActivityRecord() != null) {
final ActivityRecord activityRecord = wc.asActivityRecord();
if (activityRecord.mStartingData != null
&& activityRecord.mStartingData.mAssociatedTask != null) {
return;
}
}
if (mContainerFreezer == null) {
mContainerFreezer = new ScreenshotFreezer();