Adjust to next focusable task if top task is died
Since shell transition is enabled, there will also have a transition
animation to handle app died. Then the died activity and task won't be
removed immediately until the animation is finished.
To be more specific, TaskDisplayArea#mPreferredTopFocusableRootTask
is not changed to next task, so updateTopResumedActivityIfNeeded
will early return without calling setLastResumedActivityUncheckLocked.
Note that this will also change the animation style of the died task.
Because previously the root task of home is not collected, the
animation style is the default sliding out. Now the animation will
match the remote animation rule of launcher so it will animate scaling
to the icon on home.
Bug: 301265227
Test: Launch Settings from home.
adb shell am force-stop com.android.settings
adb shell dumpsys window | grep mFocusedApp
The output will show home activity.
Change-Id: I8c99964df9e1f2d52779d41c23c6195fe3c87af3
1 file changed