Skip to content
  • msramek's avatar
    Move BrowsingDataRemover to content/ · e169ccbe
    msramek authored
    Changes in this CL:
    
    1. The public interfaces BrowsingDataRemover and BrowsingDataRemoverDelegate
    move to content/public/browser. BrowsingDataRemoverImpl moves to
    content/browser/browsing_data.
    
    2. Previously, BrowsingDataRemoverImpl was a KeyedService created by
    BrowsingDataRemoverFactory. After this CL, it is owned by BrowserContext.
    Conversely, ChromeBrowsingRemoverDelegate (which stays in chrome/) becomes
    a KeyedService. The former BrowsingDataRemoverFactory is thus adapted into
    ChromeBrowsingDataRemoverDelegateFactory.
    
    BrowsingDataRemoverDelegate is now owned by the embedder (rather than
    BrowsingDataRemover) and supplied by embedders through
    BrowserContext::GetBrowsingDataRemoverDelegate(). Profile (in chrome/)
    supplies ChromeBrowsingDataRemoverDelegate. The implementation for other
    embedders is left as TODO.
    
    3. BrowsingDataRemoverImplTest moves to content/browser/browsing/data.
    browsing_data_remover_test_util that is used by this test as well as various
    tests in chrome/ is moved to content/public/test.
    
    4. BrowsingDataRemover can only delete download history if this is feature is
    not disabled by administrator. Previously, BrowsingDataRemover queried
    PrefService directly. We now pass this information through
    BrowsingDataRemoverDelegate. The default value is true,
    ChromeBrowsingDataRemoverDelegate queries PrefService.
    
    5. The removal of ContentBrowserClient interfaces ClearCookies(), ClearCache(),
    ClearSiteData() and their replacement by BrowsingDataRemover is left as a TODO.
    
    6. All other changes are adding / removing includes, updating BUILD files,
    replacing BrowsingDataRemoverFactory with BrowserContext::GetBrowsingDataRemover,
    formatting (mostly triggered by prepending content:: to class names), and the
    removal of forgotten "#ifdef (EXTENSIONS)" in BrowsingDataRemoverImplTest.
    
    TBR=dbeam@chromium.org
    BUG=668114
    
    Review-Url: https://codereview.chromium.org/2827523003
    Cr-Commit-Position: refs/heads/master@{#467241}
    e169ccbe