Merge "Fix decor stuck after rotate" into udc-dev am: 8b77e6b061
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/23232984 Change-Id: I971cd3fa67378542c5750ce14d138870855acc50 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -2035,18 +2035,16 @@ public class StageCoordinator implements SplitLayout.SplitLayoutHandler,
|
||||
// Reset this flag every time onLayoutSizeChanged.
|
||||
mShowDecorImmediately = false;
|
||||
|
||||
if (!ENABLE_SHELL_TRANSITIONS) {
|
||||
// Only need screenshot for legacy case because shell transition should screenshot
|
||||
// itself during transition.
|
||||
final SurfaceControl.Transaction startT = mTransactionPool.acquire();
|
||||
mMainStage.screenshotIfNeeded(startT);
|
||||
mSideStage.screenshotIfNeeded(startT);
|
||||
mTransactionPool.release(startT);
|
||||
}
|
||||
|
||||
final WindowContainerTransaction wct = new WindowContainerTransaction();
|
||||
boolean sizeChanged = updateWindowBounds(layout, wct);
|
||||
if (!sizeChanged) return;
|
||||
if (!sizeChanged) {
|
||||
// We still need to resize on decor for ensure all current status clear.
|
||||
final SurfaceControl.Transaction t = mTransactionPool.acquire();
|
||||
mMainStage.onResized(t);
|
||||
mSideStage.onResized(t);
|
||||
mTransactionPool.release(t);
|
||||
return;
|
||||
}
|
||||
|
||||
sendOnBoundsChanged();
|
||||
if (ENABLE_SHELL_TRANSITIONS) {
|
||||
@@ -2054,6 +2052,13 @@ public class StageCoordinator implements SplitLayout.SplitLayoutHandler,
|
||||
mSplitTransitions.startResizeTransition(wct, this, (finishWct, t) ->
|
||||
mSplitLayout.setDividerInteractive(true, false, "onSplitResizeFinish"));
|
||||
} else {
|
||||
// Only need screenshot for legacy case because shell transition should screenshot
|
||||
// itself during transition.
|
||||
final SurfaceControl.Transaction startT = mTransactionPool.acquire();
|
||||
mMainStage.screenshotIfNeeded(startT);
|
||||
mSideStage.screenshotIfNeeded(startT);
|
||||
mTransactionPool.release(startT);
|
||||
|
||||
mSyncQueue.queue(wct);
|
||||
mSyncQueue.runInSync(t -> {
|
||||
updateSurfaceBounds(layout, t, false /* applyResizingOffset */);
|
||||
|
||||
Reference in New Issue
Block a user