summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author wilsonshih <wilsonshih@google.com> 2023-04-13 13:58:16 +0800
committer wilsonshih <wilsonshih@google.com> 2023-04-19 19:29:49 +0800
commit8c4a7b8efd1e9edfb24a4e952ca3b9b679bc4973 (patch)
treebea2c172eac93dae41e6a606cdb279e0d609db54
parent11562e978937ef374e780993e3724be8bc1100c4 (diff)
Default hide animation leash of opening tasks.
RecentsTransitionHandler doesn't know the initial tasks position when tasks appeared, only RecentsAnimationRunner know. So there shouldn't show the animation leash immediately, otherwise the opening tasks could shows up in the final position, before RecentsAnimationRunner start the opening animation. Bug: 277704255 Test: manual, entering recents, launch another task, verify no flicker during the opening animation. Change-Id: I1c384b825348d8a67d49c4cec89a61a9a6f9687f
-rw-r--r--libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java b/libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java
index b55487258220..0482bada47cb 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/recents/RecentsTransitionHandler.java
@@ -565,6 +565,8 @@ public class RecentsTransitionHandler implements Transitions.TransitionHandler {
final int rootIdx = TransitionUtil.rootIndexFor(change, mInfo);
t.reparent(appearedTargets[i].leash, mInfo.getRoot(rootIdx).getLeash());
t.setLayer(appearedTargets[i].leash, layer);
+ // Hide the animation leash, let listener show it.
+ t.hide(appearedTargets[i].leash);
ProtoLog.v(ShellProtoLogGroup.WM_SHELL_RECENTS_TRANSITION,
" opening new taskId=%d", appearedTargets[i].taskId);
mOpeningTasks.add(new TaskState(change, appearedTargets[i].leash));