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

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

Issue 382313003: Add data reduction functionality to all platforms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove incorrect DCHECK from drp_statistics_prefs.cc Created 6 years, 3 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 | « chrome/browser/profiles/profile_io_data.h ('k') | components/data_reduction_proxy/browser/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 ff0fc7ea9308060996002b5aa70d7b2eebe56822..552658c087c9483e6bb96054005bcd8b31c08127 100644
--- a/chrome/browser/profiles/profile_io_data.cc
+++ b/chrome/browser/profiles/profile_io_data.cc
@@ -42,6 +42,7 @@
#include "chrome/browser/net/cookie_store_util.h"
#include "chrome/browser/net/proxy_service_factory.h"
#include "chrome/browser/net/resource_prefetch_predictor_observer.h"
+#include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_configurator.h"
#include "chrome/browser/predictors/resource_prefetch_predictor.h"
#include "chrome/browser/predictors/resource_prefetch_predictor_factory.h"
#include "chrome/browser/profiles/profile.h"
@@ -52,6 +53,10 @@
#include "chrome/common/pref_names.h"
#include "chrome/common/url_constants.h"
#include "components/content_settings/core/browser/content_settings_provider.h"
+#include "components/data_reduction_proxy/browser/data_reduction_proxy_config_service.h"
+#include "components/data_reduction_proxy/browser/data_reduction_proxy_configurator.h"
+#include "components/data_reduction_proxy/browser/data_reduction_proxy_settings.h"
+#include "components/data_reduction_proxy/common/data_reduction_proxy_switches.h"
#include "components/dom_distiller/core/url_constants.h"
#include "components/startup_metric_utils/startup_metric_utils.h"
#include "components/sync_driver/pref_names.h"
@@ -858,17 +863,11 @@ bool ProfileIOData::GetMetricsEnabledStateOnIOThread() const {
#endif // defined(OS_CHROMEOS)
}
-#if defined(OS_ANDROID)
bool ProfileIOData::IsDataReductionProxyEnabled() const {
-#if defined(SPDY_PROXY_AUTH_ORIGIN)
return data_reduction_proxy_enabled_.GetValue() ||
CommandLine::ForCurrentProcess()->HasSwitch(
data_reduction_proxy::switches::kEnableDataReductionProxy);
-#else
- return false;
-#endif // defined(SPDY_PROXY_AUTH_ORIGIN)
}
-#endif
base::WeakPtr<net::HttpServerProperties>
ProfileIOData::http_server_properties() const {
@@ -1024,10 +1023,8 @@ void ProfileIOData::Init(
network_delegate->set_cookie_settings(profile_params_->cookie_settings.get());
network_delegate->set_enable_do_not_track(&enable_do_not_track_);
network_delegate->set_force_google_safe_search(&force_safesearch_);
-#if defined(SPDY_PROXY_AUTH_ORIGIN)
network_delegate->set_data_reduction_proxy_enabled_pref(
&data_reduction_proxy_enabled_);
-#endif
network_delegate->set_prerender_tracker(profile_params_->prerender_tracker);
network_delegate_.reset(network_delegate);
@@ -1045,7 +1042,6 @@ void ProfileIOData::Init(
profile_params_->proxy_config_service.release(),
command_line,
quick_check_enabled_.GetValue()));
-
transport_security_state_.reset(new net::TransportSecurityState());
transport_security_persister_.reset(
new net::TransportSecurityPersister(
@@ -1206,9 +1202,7 @@ void ProfileIOData::ShutdownOnUIThread(
enable_metrics_.Destroy();
#endif
safe_browsing_enabled_.Destroy();
-#if defined(SPDY_PROXY_AUTH_ORIGIN)
data_reduction_proxy_enabled_.Destroy();
-#endif
printing_enabled_.Destroy();
sync_disabled_.Destroy();
signin_allowed_.Destroy();
« no previous file with comments | « chrome/browser/profiles/profile_io_data.h ('k') | components/data_reduction_proxy/browser/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698