Add missing startHomeActivity call during user-start..
When switching to a foreground user whose top task should be home. This fixes a regression from Ib42d707d0f5c279042080c004044667a11c74f0c that causes the SetUpWizard to not show for newly created users. To include this activity start in the same user-switch transition, this change also refactors UserController and WindowManagerService such that: 1) The early call to WMS#prepareUserStart (formerly #setCurrentUser) does not make any changes to window containers. Those will be made later when the transition is requested. Instead it runs other side effects that must happen early in the user-start flow (such as WindowManagerPolicy#setCurrentUserLw that must be sent before new user id broadcasts are sent). 2) All window container changes that were spread out before (RootWindowContainer#switchUser, DisplayContent density, resume top activities, startHomeActivity) are now wrapped be the user-switch transition started in WindowManagerService#startUserSwitchTransition. Flag: com.android.window.flags.apply_desk_activation_on_user_switch Fix: 439970292 Test: flash device, set up default user, go to Settings and change display size, then create a new user and switch to it - verify the SUW is started instead of skipping it and going directly to the launcher. Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:2b597ab1a6bfc28b802b39c2e97cdff9b8df5917 Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:844ddc15f923319b6ec9e1c84dc3ed1778caf7fa Merged-In: Id287d4ffb038c27c6e7dfbe472d64129a19b887c Change-Id: Id287d4ffb038c27c6e7dfbe472d64129a19b887c
Loading
Please register or sign in to comment