| Index: android_webview/browser/net/aw_url_request_context_getter.cc
|
| diff --git a/android_webview/browser/net/aw_url_request_context_getter.cc b/android_webview/browser/net/aw_url_request_context_getter.cc
|
| index f00ef59a53c6d9d23a5bbf459ba467629eb4a1c8..ed3d7dfd13c3928d6a365d9aed8097a5e9772d78 100644
|
| --- a/android_webview/browser/net/aw_url_request_context_getter.cc
|
| +++ b/android_webview/browser/net/aw_url_request_context_getter.cc
|
| @@ -20,6 +20,7 @@
|
| #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.h"
|
| #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_config_service.h"
|
| #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_interceptor.h"
|
| +#include "components/data_reduction_proxy/core/browser/data_reduction_proxy_io_data.h"
|
| #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.h"
|
| #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_settings.h"
|
| #include "content/public/browser/browser_thread.h"
|
| @@ -204,25 +205,12 @@ void AwURLRequestContextGetter::InitializeURLRequestContext() {
|
| // Compression statistics are not gathered for WebView, so
|
| // DataReductionProxyStatisticsPrefs is not instantiated and passed to the
|
| // network delegate.
|
| - DataReductionProxySettings* data_reduction_proxy_settings =
|
| - browser_context->GetDataReductionProxySettings();
|
| - DCHECK(data_reduction_proxy_settings);
|
| - data_reduction_proxy_auth_request_handler_.reset(
|
| - new data_reduction_proxy::DataReductionProxyAuthRequestHandler(
|
| - data_reduction_proxy::Client::WEBVIEW_ANDROID,
|
| - data_reduction_proxy_settings->params(),
|
| - BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO)));
|
| -
|
| - data_reduction_proxy::DataReductionProxyNetworkDelegate*
|
| - data_reduction_proxy_network_delegate =
|
| - new data_reduction_proxy::DataReductionProxyNetworkDelegate(
|
| - aw_network_delegate.Pass(),
|
| - data_reduction_proxy_settings->params(),
|
| - data_reduction_proxy_auth_request_handler_.get(),
|
| - data_reduction_proxy::DataReductionProxyNetworkDelegate::
|
| - ProxyConfigGetter());
|
| -
|
| - builder.set_network_delegate(data_reduction_proxy_network_delegate);
|
| +
|
| + browser_context->GetDataReductionProxyIOData()->Init(
|
| + aw_network_delegate.Pass(), false, false, false);
|
| +
|
| + builder.set_network_delegate(
|
| + browser_context->GetDataReductionProxyIOData()->network_delegate());
|
| #if !defined(DISABLE_FTP_SUPPORT)
|
| builder.set_ftp_enabled(false); // Android WebView does not support ftp yet.
|
| #endif
|
| @@ -265,9 +253,8 @@ void AwURLRequestContextGetter::InitializeURLRequestContext() {
|
|
|
| job_factory_.reset(new net::URLRequestInterceptingJobFactory(
|
| job_factory_.Pass(), make_scoped_ptr(
|
| - new data_reduction_proxy::DataReductionProxyInterceptor(
|
| - data_reduction_proxy_settings->params(), NULL,
|
| - browser_context->GetDataReductionProxyEventStore()))));
|
| + browser_context->GetDataReductionProxyIOData()->
|
| + CreateInterceptor())));
|
| url_request_context_->set_job_factory(job_factory_.get());
|
| }
|
|
|
|
|