Skip to content
Snippets Groups Projects
Commit 6f566b76 authored by Hongwei Wang's avatar Hongwei Wang Committed by Android (Google) Code Review
Browse files

Merge "Work around the flicker on enter PiP for foldables" into main

parents fac4d51a 0e6c3144
No related branches found
No related tags found
No related merge requests found
......@@ -16,6 +16,8 @@
package com.android.wm.shell.unfold;
import static android.app.WindowConfiguration.WINDOWING_MODE_PINNED;
import android.annotation.NonNull;
import android.app.ActivityManager.RunningTaskInfo;
import android.app.TaskInfo;
......@@ -28,11 +30,11 @@ import com.android.wm.shell.sysui.ShellInit;
import com.android.wm.shell.unfold.ShellUnfoldProgressProvider.UnfoldListener;
import com.android.wm.shell.unfold.animation.UnfoldTaskAnimator;
import dagger.Lazy;
import java.util.List;
import java.util.Optional;
import dagger.Lazy;
/**
* Manages fold/unfold animations of tasks on foldable devices.
* When folding or unfolding a foldable device we play animations that
......@@ -228,7 +230,8 @@ public class UnfoldAnimationController implements UnfoldListener {
}
private void maybeResetTask(UnfoldTaskAnimator animator, TaskInfo taskInfo) {
if (!mIsInStageChange) {
// TODO(b/311084698): the windowing mode check is added here as a work around.
if (!mIsInStageChange || taskInfo.getWindowingMode() == WINDOWING_MODE_PINNED) {
// No need to resetTask if there is no ongoing state change.
return;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment