Loading services/core/java/com/android/server/wm/ActivityRecord.java +1 −0 Original line number Diff line number Diff line Loading @@ -4383,6 +4383,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A return; } mVisibleRequested = visible; setInsetsFrozen(!visible); if (app != null) { mTaskSupervisor.onProcessActivityStateChanged(app, false /* forceBatch */); } Loading services/core/java/com/android/server/wm/DisplayContent.java +0 −7 Original line number Diff line number Diff line Loading @@ -4101,13 +4101,6 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp */ void onWindowAnimationFinished(@NonNull WindowContainer wc, int type) { if (type == ANIMATION_TYPE_APP_TRANSITION || type == ANIMATION_TYPE_RECENTS) { // Unfreeze the insets state of the frozen target when the animation finished if exists. final Task task = wc.asTask(); if (task != null) { task.forAllWindows(w -> { w.clearFrozenInsetsState(); }, true /* traverseTopToBottom */); } removeImeSurfaceImmediately(); } } Loading services/core/java/com/android/server/wm/WindowContainer.java +0 −8 Original line number Diff line number Diff line Loading @@ -2684,14 +2684,6 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< @Nullable ArrayList<WindowContainer> sources) { final Task task = asTask(); if (task != null && !enter && !task.isHomeOrRecentsRootTask()) { if (AppTransition.isClosingTransitOld(transit)) { // Freezes the insets state when the window is in app exiting transition, to // ensure the exiting window won't receive unexpected insets changes from the // next window. task.forAllWindows(w -> { w.freezeInsetsState(); }, true /* traverseTopToBottom */); } mDisplayContent.showImeScreenshot(); } final Pair<AnimationAdapter, AnimationAdapter> adapters = getAnimationAdapter(lp, Loading services/core/java/com/android/server/wm/WindowState.java +1 −1 Original line number Diff line number Diff line Loading @@ -797,7 +797,7 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP * {@link InsetsStateController#notifyInsetsChanged}. */ boolean isReadyToDispatchInsetsState() { return isVisible() && mFrozenInsetsState == null; return isVisibleRequested() && mFrozenInsetsState == null; } void seamlesslyRotateIfAllowed(Transaction transaction, @Rotation int oldRotation, Loading services/core/java/com/android/server/wm/WindowToken.java +9 −0 Original line number Diff line number Diff line Loading @@ -736,4 +736,13 @@ class WindowToken extends WindowContainer<WindowState> { boolean isFromClient() { return mFromClientToken; } /** @see WindowState#freezeInsetsState() */ void setInsetsFrozen(boolean freeze) { if (freeze) { forAllWindows(WindowState::freezeInsetsState, true /* traverseTopToBottom */); } else { forAllWindows(WindowState::clearFrozenInsetsState, true /* traverseTopToBottom */); } } } Loading
services/core/java/com/android/server/wm/ActivityRecord.java +1 −0 Original line number Diff line number Diff line Loading @@ -4383,6 +4383,7 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A return; } mVisibleRequested = visible; setInsetsFrozen(!visible); if (app != null) { mTaskSupervisor.onProcessActivityStateChanged(app, false /* forceBatch */); } Loading
services/core/java/com/android/server/wm/DisplayContent.java +0 −7 Original line number Diff line number Diff line Loading @@ -4101,13 +4101,6 @@ class DisplayContent extends RootDisplayArea implements WindowManagerPolicy.Disp */ void onWindowAnimationFinished(@NonNull WindowContainer wc, int type) { if (type == ANIMATION_TYPE_APP_TRANSITION || type == ANIMATION_TYPE_RECENTS) { // Unfreeze the insets state of the frozen target when the animation finished if exists. final Task task = wc.asTask(); if (task != null) { task.forAllWindows(w -> { w.clearFrozenInsetsState(); }, true /* traverseTopToBottom */); } removeImeSurfaceImmediately(); } } Loading
services/core/java/com/android/server/wm/WindowContainer.java +0 −8 Original line number Diff line number Diff line Loading @@ -2684,14 +2684,6 @@ class WindowContainer<E extends WindowContainer> extends ConfigurationContainer< @Nullable ArrayList<WindowContainer> sources) { final Task task = asTask(); if (task != null && !enter && !task.isHomeOrRecentsRootTask()) { if (AppTransition.isClosingTransitOld(transit)) { // Freezes the insets state when the window is in app exiting transition, to // ensure the exiting window won't receive unexpected insets changes from the // next window. task.forAllWindows(w -> { w.freezeInsetsState(); }, true /* traverseTopToBottom */); } mDisplayContent.showImeScreenshot(); } final Pair<AnimationAdapter, AnimationAdapter> adapters = getAnimationAdapter(lp, Loading
services/core/java/com/android/server/wm/WindowState.java +1 −1 Original line number Diff line number Diff line Loading @@ -797,7 +797,7 @@ class WindowState extends WindowContainer<WindowState> implements WindowManagerP * {@link InsetsStateController#notifyInsetsChanged}. */ boolean isReadyToDispatchInsetsState() { return isVisible() && mFrozenInsetsState == null; return isVisibleRequested() && mFrozenInsetsState == null; } void seamlesslyRotateIfAllowed(Transaction transaction, @Rotation int oldRotation, Loading
services/core/java/com/android/server/wm/WindowToken.java +9 −0 Original line number Diff line number Diff line Loading @@ -736,4 +736,13 @@ class WindowToken extends WindowContainer<WindowState> { boolean isFromClient() { return mFromClientToken; } /** @see WindowState#freezeInsetsState() */ void setInsetsFrozen(boolean freeze) { if (freeze) { forAllWindows(WindowState::freezeInsetsState, true /* traverseTopToBottom */); } else { forAllWindows(WindowState::clearFrozenInsetsState, true /* traverseTopToBottom */); } } }