Merge "Capture task snapshot with initial bounds during finish transition." into udc-dev

This commit is contained in:
Wei Sheng Shih
2023-04-26 03:09:29 +00:00
committed by Android (Google) Code Review

View File

@@ -239,7 +239,17 @@ abstract class AbsAppSnapshotController<TYPE extends WindowContainer,
}
return null;
}
source.getBounds(mTmpRect);
mTmpRect.setEmpty();
if (source.mTransitionController.inFinishingTransition(source)) {
final Transition.ChangeInfo changeInfo = source.mTransitionController
.mFinishingTransition.mChanges.get(source);
if (changeInfo != null) {
mTmpRect.set(changeInfo.mAbsoluteBounds);
}
}
if (mTmpRect.isEmpty()) {
source.getBounds(mTmpRect);
}
mTmpRect.offsetTo(0, 0);
SurfaceControl[] excludeLayers;
final WindowState imeWindow = source.getDisplayContent().mInputMethodWindow;