Merge "Avoid potential recursion of surface placement" into tm-qpr-dev

This commit is contained in:
Riddle Hsu
2022-07-28 10:33:58 +00:00
committed by Android (Google) Code Review
2 changed files with 5 additions and 1 deletions

View File

@@ -779,6 +779,10 @@ class RootWindowContainer extends WindowContainer<DisplayContent>
return leakedSurface || killedApps;
}
/**
* This method should only be called from {@link WindowSurfacePlacer}. Otherwise the recursion
* check and {@link WindowSurfacePlacer#isInLayout()} won't take effect.
*/
void performSurfacePlacement() {
Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, "performSurfacePlacement");
try {

View File

@@ -5611,7 +5611,7 @@ public class WindowManagerService extends IWindowManager.Stub
mWindowsInsetsChanged = 0;
// We need to update resizing windows and dispatch the new insets state
// to them.
mRoot.performSurfacePlacement();
mWindowPlacerLocked.performSurfacePlacement();
}
}
break;