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

Unified Diff: chrome/browser/browser_process_impl.cc

Issue 2731283009: Swap ownership of RulesetService and the content delegate (Closed)
Patch Set: engedy review Created 3 years, 9 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
Index: chrome/browser/browser_process_impl.cc
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc
index be342085d4c81cde97e4375b29079b4685152651..08f28a142c3dae7ce6b5600e8dc7578438e785f1 100644
--- a/chrome/browser/browser_process_impl.cc
+++ b/chrome/browser/browser_process_impl.cc
@@ -104,7 +104,7 @@
#include "components/rappor/rappor_service_impl.h"
#include "components/safe_json/safe_json_parser.h"
#include "components/signin/core/common/profile_management_switches.h"
-#include "components/subresource_filter/content/browser/content_ruleset_service_delegate.h"
+#include "components/subresource_filter/content/browser/content_ruleset_service.h"
#include "components/subresource_filter/core/browser/ruleset_service.h"
#include "components/subresource_filter/core/browser/subresource_filter_constants.h"
#include "components/subresource_filter/core/browser/subresource_filter_features.h"
@@ -903,7 +903,7 @@ safe_browsing::ClientSideDetectionService*
return NULL;
}
-subresource_filter::RulesetService*
+subresource_filter::ContentRulesetService*
BrowserProcessImpl::subresource_filter_ruleset_service() {
DCHECK(CalledOnValidThread());
if (!created_subresource_filter_ruleset_service_)
@@ -1224,11 +1224,12 @@ void BrowserProcessImpl::CreateSubresourceFilterRulesetService() {
base::FilePath indexed_ruleset_base_dir =
user_data_dir.Append(subresource_filter::kTopLevelDirectoryName)
.Append(subresource_filter::kIndexedRulesetBaseDirectoryName);
- subresource_filter_ruleset_service_.reset(
- new subresource_filter::RulesetService(
+ subresource_filter_ruleset_service_ =
+ base::MakeUnique<subresource_filter::ContentRulesetService>();
+ subresource_filter_ruleset_service_->set_ruleset_service(
+ base::MakeUnique<subresource_filter::RulesetService>(
local_state(), blocking_task_runner,
- base::MakeUnique<subresource_filter::ContentRulesetServiceDelegate>(),
- indexed_ruleset_base_dir));
+ subresource_filter_ruleset_service_.get(), indexed_ruleset_base_dir));
}
void BrowserProcessImpl::CreateGCMDriver() {
« no previous file with comments | « chrome/browser/browser_process_impl.h ('k') | chrome/browser/component_updater/subresource_filter_component_installer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698