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

Unified Diff: chrome/browser/profiles/profile_io_data.cc

Issue 1786263002: Remove uses of ENABLE_CONFIGURATION_POLICY from src/chrome. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sort Created 4 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/profiles/profile_io_data.cc
diff --git a/chrome/browser/profiles/profile_io_data.cc b/chrome/browser/profiles/profile_io_data.cc
index aaea4da2bbf81b0bf6bfa606c89e93198d7cc6b0..c4e0cd99ea99340dd0a1c09db223a65b0e501053 100644
--- a/chrome/browser/profiles/profile_io_data.cc
+++ b/chrome/browser/profiles/profile_io_data.cc
@@ -41,6 +41,8 @@
#include "chrome/browser/net/chrome_url_request_context_getter.h"
#include "chrome/browser/net/proxy_service_factory.h"
#include "chrome/browser/net/resource_prefetch_predictor_observer.h"
+#include "chrome/browser/policy/cloud/policy_header_service_factory.h"
+#include "chrome/browser/policy/policy_helpers.h"
#include "chrome/browser/predictors/resource_prefetch_predictor.h"
#include "chrome/browser/predictors/resource_prefetch_predictor_factory.h"
#include "chrome/browser/profiles/profile.h"
@@ -62,6 +64,10 @@
#include "components/dom_distiller/core/url_constants.h"
#include "components/metrics/metrics_pref_names.h"
#include "components/net_log/chrome_net_log.h"
+#include "components/policy/core/browser/url_blacklist_manager.h"
+#include "components/policy/core/common/cloud/policy_header_io_helper.h"
+#include "components/policy/core/common/cloud/policy_header_service.h"
+#include "components/policy/core/common/cloud/user_cloud_policy_manager.h"
#include "components/prefs/pref_service.h"
#include "components/signin/core/common/signin_pref_names.h"
#include "components/sync_driver/pref_names.h"
@@ -96,15 +102,6 @@
#include "net/url_request/url_request_interceptor.h"
#include "net/url_request/url_request_job_factory_impl.h"
-#if defined(ENABLE_CONFIGURATION_POLICY)
-#include "chrome/browser/policy/cloud/policy_header_service_factory.h"
-#include "chrome/browser/policy/policy_helpers.h"
-#include "components/policy/core/browser/url_blacklist_manager.h"
-#include "components/policy/core/common/cloud/policy_header_io_helper.h"
-#include "components/policy/core/common/cloud/policy_header_service.h"
-#include "components/policy/core/common/cloud/user_cloud_policy_manager.h"
-#endif
-
#if defined(ENABLE_EXTENSIONS)
#include "chrome/browser/extensions/extension_cookie_monster_delegate.h"
#include "chrome/browser/extensions/extension_resource_protocols.h"
@@ -518,7 +515,6 @@ void ProfileIOData::InitializeOnUIThread(Profile* profile) {
// ShutdownOnUIThread to release these observers on the right thread.
// Don't pass it in |profile_params_| to make sure it is correctly cleaned up,
// in particular when this ProfileIOData isn't |initialized_| during deletion.
-#if defined(ENABLE_CONFIGURATION_POLICY)
policy::URLBlacklist::SegmentURLCallback callback =
static_cast<policy::URLBlacklist::SegmentURLCallback>(
url_formatter::SegmentURL);
@@ -538,7 +534,6 @@ void ProfileIOData::InitializeOnUIThread(Profile* profile) {
policy_header_service->CreatePolicyHeaderIOHelper(io_task_runner);
}
}
-#endif
incognito_availibility_pref_.Init(
prefs::kIncognitoModeAvailability, pref_service);
@@ -1038,9 +1033,7 @@ void ProfileIOData::Init(
}
#endif
-#if defined(ENABLE_CONFIGURATION_POLICY)
network_delegate->set_url_blacklist_manager(url_blacklist_manager_.get());
-#endif
network_delegate->set_profile(profile_params_->profile);
network_delegate->set_profile_path(profile_params_->path);
network_delegate->set_cookie_settings(profile_params_->cookie_settings.get());
@@ -1260,10 +1253,8 @@ void ProfileIOData::ShutdownOnUIThread(
if (media_device_id_salt_.get())
media_device_id_salt_->ShutdownOnUIThread();
session_startup_pref_.Destroy();
-#if defined(ENABLE_CONFIGURATION_POLICY)
if (url_blacklist_manager_)
url_blacklist_manager_->ShutdownOnUIThread();
-#endif
if (chrome_http_user_agent_settings_)
chrome_http_user_agent_settings_->CleanupOnUIThread();
incognito_availibility_pref_.Destroy();
« no previous file with comments | « chrome/browser/profiles/profile_io_data.h ('k') | chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698