• Stepan Khapugin's avatar
    [multiball] Remove differences on iOS 12 and 13 wrt startupChromeUI. · b4b9fc4f
    Stepan Khapugin authored
    Before this CL, MainController calls startUpChromeUI on the scene on iOS
    12.
    
    With this CL, this exceptional call is removed. Instead, the call now
    always happens in SceneController. The follow-up call to
    startUpAfterFirstWindowCreated in MainController is now triggered
    through the appState:firstSceneActivated: observer callback in both old
    and new startup sequences.
    
    This requires a few minor changes:
    * AppState now observes SceneWillConnect and immediately adds itself
    as a SceneState observer. The UISceneDidActivateNotification observation
    is now replaced with sceneState:transitionedToActivationLevel:, which
    is available on both iOS 12 and 13.
    * SceneController now becomes an AppStateObserver immediately on init,
    instead of waiting to initializeUI.
    
    Minor win: SceneControllerGuts are no longer necessary.
    
    Bug: 1012697
    Change-Id: Id82e6a10c5825e34f53f076fef19a1e6bf9e7908
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2398505
    Commit-Queue: Stepan Khapugin <stkhapugin@chromium.org>
    Reviewed-by: default avatarSylvain Defresne <sdefresne@chromium.org>
    Reviewed-by: default avatarMark Cogan <marq@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#807938}
    b4b9fc4f
scene_controller.mm 93.4 KB