• nkostylev's avatar
    [session_manager] Move user session initialization code out of ExistingUserController · 609c2d1d
    nkostylev authored
    Added UserSessionManager::InitializeUserSession()
    (1) Launches browser for most common case
    (2) Continues new user sign in with TOS (public sessions)/image screen (new users)
    (3) For kiosk flow delegates launching app to the existing kiosk initialization flow
    
    (1) Currently results in LoginUtils::Get()->DoBrowserLaunch() which may postpone launching browser for these reasons:
    (a) There's custom user login flow defined like SupervisedUserCreationFlow. In that case login UI continues to live and custom flow UI is launched in that context.
    (b) User has different app locale which requires reloading resource_bundle prior to launching browser
    (c) User has custom flags set (or user flags are different from login screen flags defined by the owner), this requires restarting Chrome which will be launched in the active user session.
    
    Small refactoring in ExistingUserController, added
    
    * PerformPreLoginActions() - performs sets of actions right prior to login has been started.
    * PerformLoginFinishedActions() - performs set of actions when login has been completed or has been cancelled.
    
    BUG=370175
    
    Review URL: https://codereview.chromium.org/656283002
    
    Cr-Commit-Position: refs/heads/master@{#300708}
    609c2d1d
test_login_utils.cc 1.26 KB