Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(833)

Side by Side Diff: chrome/browser/precache/precache_manager_factory.cc

Issue 2544613003: Disable precache if data_reduction_proxy enabled. (Closed)
Patch Set: Rebase. Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | components/precache/content/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/precache/precache_manager_factory.h" 5 #include "chrome/browser/precache/precache_manager_factory.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility>
8 9
9 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
10 #include "chrome/browser/history/history_service_factory.h" 11 #include "chrome/browser/history/history_service_factory.h"
12 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings.h"
13 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings_fact ory.h"
11 #include "chrome/browser/profiles/profile.h" 14 #include "chrome/browser/profiles/profile.h"
12 #include "chrome/browser/sync/profile_sync_service_factory.h" 15 #include "chrome/browser/sync/profile_sync_service_factory.h"
13 #include "components/keyed_service/content/browser_context_dependency_manager.h" 16 #include "components/keyed_service/content/browser_context_dependency_manager.h"
14 #include "components/keyed_service/core/service_access_type.h" 17 #include "components/keyed_service/core/service_access_type.h"
15 #include "components/precache/content/precache_manager.h" 18 #include "components/precache/content/precache_manager.h"
16 #include "components/precache/core/precache_database.h" 19 #include "components/precache/core/precache_database.h"
17 #include "content/public/browser/browser_context.h" 20 #include "content/public/browser/browser_context.h"
18 21
19 namespace precache { 22 namespace precache {
20 23
(...skipping 24 matching lines...) Expand all
45 new PrecacheDatabase()); 48 new PrecacheDatabase());
46 base::FilePath db_path(browser_context->GetPath().Append( 49 base::FilePath db_path(browser_context->GetPath().Append(
47 base::FilePath(FILE_PATH_LITERAL("PrecacheDatabase")))); 50 base::FilePath(FILE_PATH_LITERAL("PrecacheDatabase"))));
48 return new PrecacheManager( 51 return new PrecacheManager(
49 browser_context, 52 browser_context,
50 ProfileSyncServiceFactory::GetSyncServiceForBrowserContext( 53 ProfileSyncServiceFactory::GetSyncServiceForBrowserContext(
51 browser_context), 54 browser_context),
52 HistoryServiceFactory::GetForProfile( 55 HistoryServiceFactory::GetForProfile(
53 Profile::FromBrowserContext(browser_context), 56 Profile::FromBrowserContext(browser_context),
54 ServiceAccessType::IMPLICIT_ACCESS), 57 ServiceAccessType::IMPLICIT_ACCESS),
58 DataReductionProxyChromeSettingsFactory::GetForBrowserContext(
59 browser_context),
55 db_path, std::move(precache_database)); 60 db_path, std::move(precache_database));
56 } 61 }
57 62
58 } // namespace precache 63 } // namespace precache
OLDNEW
« no previous file with comments | « no previous file | components/precache/content/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698