Trigger onTaskAppeared when a task started from recents becomes ready.
In quick switch flows, launcher will first swipe task snapshot through recents animation, and then start new task with custom animation options through startActivityFromRecents after gesture finish detected, and then finish recents animation finally. But that way user may experience flickering before the new task launch and recents animation finish. To improve quick switch flickering, we ignore the new task's custom animation from recents and generate task remote animation target, and then trigger a callback for launcher to control/animate this task surface, more like a part of RecentsAnimation, Also, adding removeTask method for launcher can flexibility remove the new task animation target once no need to animate, so that launcher can decide when to finish recents animation. Bug: 152480470 Test: manual as below steps: 1) Doing quick switch task. 2) Make sure launcher can receive onTaskAppeared callback. 3) Make sure launcher calls removeTask successfully. 4) Make sure launcher can finish recents animation after 3). Change-Id: I0692a280a49719229fa8871509bad37a1343a00f
Loading
Please register or sign in to comment