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

Unified Diff: chrome/browser/browser_process_impl.cc

Issue 1291543004: Inject JSON parsing in WebResource as a callback rather than inheritance (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@webResources1
Patch Set: Created 5 years, 4 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/plugins/plugins_resource_service.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/browser_process_impl.cc
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc
index 00da45d6a3afa9f5465c61f269898c012606a047..c236055825b9c05e858ffdd675c2ec81215f23e0 100644
--- a/chrome/browser/browser_process_impl.cc
+++ b/chrome/browser/browser_process_impl.cc
@@ -80,6 +80,7 @@
#include "components/metrics/metrics_service.h"
#include "components/network_time/network_time_tracker.h"
#include "components/policy/core/common/policy_service.h"
+#include "components/safe_json/safe_json_parser.h"
#include "components/signin/core/common/profile_management_switches.h"
#include "components/translate/core/browser/translate_download_manager.h"
#include "components/update_client/update_query_params.h"
@@ -1068,8 +1069,10 @@ void BrowserProcessImpl::PreMainMessageLoopRun() {
*base::CommandLine::ForCurrentProcess();
if (!command_line.HasSwitch(switches::kDisableWebResources)) {
DCHECK(!promo_resource_service_.get());
- promo_resource_service_.reset(
- new PromoResourceService(local_state(), chrome::GetChannel()));
+ promo_resource_service_.reset(new PromoResourceService(
+ local_state(), chrome::GetChannel(), GetApplicationLocale(),
+ system_request_context(), switches::kDisableBackgroundNetworking,
+ base::Bind(safe_json::SafeJsonParser::Parse)));
promo_resource_service_->StartAfterDelay();
}
« no previous file with comments | « no previous file | chrome/browser/plugins/plugins_resource_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698