Do not set TaskFragment surface position if in change transition

When it is freezed in change transition, the animation handler should
handle the position change. After the animation leash is removed, the
TaskFragment position will be updated in #onAnimationLeashLost

Bug: 196173550
Test: test with demo app
Change-Id: I4048dbe8ae0db0354cd9bf0ef08bab9d897a65b0
This commit is contained in:
Chris Li
2021-09-19 10:45:33 +08:00
parent 79ab7ea034
commit d4a6bad8cd

View File

@@ -2046,9 +2046,7 @@ class TaskFragment extends WindowContainer<WindowContainer> {
if (shouldStartChangeTransition(mTmpPrevBounds)) {
initializeChangeTransition(mTmpPrevBounds);
}
if (mTaskFragmentOrganizer != null) {
} else if (mTaskFragmentOrganizer != null) {
// Update the surface position here instead of in the organizer so that we can make sure
// it can be synced with the surface freezer.
updateSurfacePosition(getSyncTransaction());