• Clark DuVall's avatar
    Migrate ResourceRequestAllowedNotifier to NetworkConnectionTracker · a9ed46b7
    Clark DuVall authored
    A getter is used for NetworkConnectionTracker because some services that
    use ResourceRequestAllowedNotifier are initialized early in browser
    startup (e.g. VariationsService), and only perform the initialization
    of ResourceRequestAllowedNotifier later on the UI thread. The getter
    allows us to run get the connection tracker at that point so we don't get
    DCHECKs about being on the UI thread when running
    content::GetNetworkConnectionTracker().
    
    This also moves the NetworkConnectionTracker in ios/ from BrowserState to
    ApplicationContext, which is available everywhere. It also matches non-IOS
    usage more closely, since we have it as a global there.
    
    Bug: 868021
    Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;master.tryserver.chromium.mac:ios-simulator-cronet
    Change-Id: I130c6b47feb90f0f7f0776ccc65666414a1ae802
    Reviewed-on: https://chromium-review.googlesource.com/1180360Reviewed-by: default avatarEugene But <eugenebut@chromium.org>
    Reviewed-by: default avatarRobert Sesek <rsesek@chromium.org>
    Reviewed-by: default avatarJohn Abd-El-Malek <jam@chromium.org>
    Reviewed-by: default avatarRobbie McElrath <rmcelrath@chromium.org>
    Commit-Queue: Clark DuVall <cduvall@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#584849}
    a9ed46b7
translate_service.h 2.05 KB