• Xi Han's avatar
    Split ContentMain start and ServiceManager Start. · a1105c68
    Xi Han authored
    With "allow-start-service-manager-only" flag, we can start the service
    manager without starting the remaining parts of the browser,
    particularly the browser main loop. Later, we could start the full
    browser with the service manager running. Currently, both code path go
    through service_manager::main(). Therefore, we need to avoid calling the
    initialization in service_manager::main() multiple times.
    
    In this CL:
    1. service_manager::main() checks its static bool flag to decide
       whether initialization should be called.
    2. Plumbs the start-service-manager-only flag to the ContentMainRunner
       who starts the browser main loop.
    
    This CL impacts Android only for now. It follows up CL:
     https://crrev.com/c/1093303.
    
    BUG=854209, 846846
    
    Change-Id: I7fcfb804ce7f3065da7df12947674344fe2f56d6
    Reviewed-on: https://chromium-review.googlesource.com/1114077
    Commit-Queue: Xi Han <hanxi@chromium.org>
    Reviewed-by: default avatarKen Rockot <rockot@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#574169}
    a1105c68
content_main_runner_impl.cc 36.6 KB