OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/net/chrome_network_delegate.h" | 5 #include "chrome/browser/net/chrome_network_delegate.h" |
6 | 6 |
7 #include <stdlib.h> | 7 #include <stdlib.h> |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
434 | 434 |
435 void ChromeNetworkDelegate::OnResolveProxy( | 435 void ChromeNetworkDelegate::OnResolveProxy( |
436 const GURL& url, | 436 const GURL& url, |
437 int load_flags, | 437 int load_flags, |
438 const net::ProxyService& proxy_service, | 438 const net::ProxyService& proxy_service, |
439 net::ProxyInfo* result) { | 439 net::ProxyInfo* result) { |
440 if (!on_resolve_proxy_handler_.is_null() && | 440 if (!on_resolve_proxy_handler_.is_null() && |
441 !proxy_config_getter_.is_null()) { | 441 !proxy_config_getter_.is_null()) { |
442 on_resolve_proxy_handler_.Run(url, load_flags, | 442 on_resolve_proxy_handler_.Run(url, load_flags, |
443 proxy_config_getter_.Run(), | 443 proxy_config_getter_.Run(), |
| 444 proxy_service.config(), |
444 proxy_service.proxy_retry_info(), | 445 proxy_service.proxy_retry_info(), |
445 data_reduction_proxy_params_, result); | 446 data_reduction_proxy_params_, result); |
446 } | 447 } |
447 } | 448 } |
448 | 449 |
449 void ChromeNetworkDelegate::OnProxyFallback(const net::ProxyServer& bad_proxy, | 450 void ChromeNetworkDelegate::OnProxyFallback(const net::ProxyServer& bad_proxy, |
450 int net_error) { | 451 int net_error) { |
451 if (data_reduction_proxy_usage_stats_) { | 452 if (data_reduction_proxy_usage_stats_) { |
452 data_reduction_proxy_usage_stats_->OnProxyFallback( | 453 data_reduction_proxy_usage_stats_->OnProxyFallback( |
453 bad_proxy, net_error); | 454 bad_proxy, net_error); |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
818 if (data_reduction_proxy_statistics_prefs_) { | 819 if (data_reduction_proxy_statistics_prefs_) { |
819 StoreAccumulatedContentLength(received_content_length, | 820 StoreAccumulatedContentLength(received_content_length, |
820 original_content_length, | 821 original_content_length, |
821 request_type, | 822 request_type, |
822 reinterpret_cast<Profile*>(profile_), | 823 reinterpret_cast<Profile*>(profile_), |
823 data_reduction_proxy_statistics_prefs_); | 824 data_reduction_proxy_statistics_prefs_); |
824 } | 825 } |
825 received_content_length_ += received_content_length; | 826 received_content_length_ += received_content_length; |
826 original_content_length_ += original_content_length; | 827 original_content_length_ += original_content_length; |
827 } | 828 } |
OLD | NEW |