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

Side by Side Diff: chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate.cc

Issue 398853003: [Android] Enable SB protection when --enable-spdy-proxy-auth is on. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix compilation in other platforms Created 6 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/renderer_host/chrome_resource_dispatcher_host_delegate. h" 5 #include "chrome/browser/renderer_host/chrome_resource_dispatcher_host_delegate. h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/base64.h" 10 #include "base/base64.h"
(...skipping 470 matching lines...) Expand 10 before | Expand all | Expand 10 after
481 net::URLRequest* request, 481 net::URLRequest* request,
482 content::ResourceContext* resource_context, 482 content::ResourceContext* resource_context,
483 ResourceType::Type resource_type, 483 ResourceType::Type resource_type,
484 ScopedVector<content::ResourceThrottle>* throttles) { 484 ScopedVector<content::ResourceThrottle>* throttles) {
485 ProfileIOData* io_data = ProfileIOData::FromResourceContext(resource_context); 485 ProfileIOData* io_data = ProfileIOData::FromResourceContext(resource_context);
486 #if defined(FULL_SAFE_BROWSING) || defined(MOBILE_SAFE_BROWSING) 486 #if defined(FULL_SAFE_BROWSING) || defined(MOBILE_SAFE_BROWSING)
487 // Insert safe browsing at the front of the list, so it gets to decide on 487 // Insert safe browsing at the front of the list, so it gets to decide on
488 // policies first. 488 // policies first.
489 if (io_data->safe_browsing_enabled()->GetValue() 489 if (io_data->safe_browsing_enabled()->GetValue()
490 #if defined(OS_ANDROID) 490 #if defined(OS_ANDROID)
491 || io_data->data_reduction_proxy_enabled()->GetValue() 491 || io_data->IsDataReductionProxyEnabled()
492 #endif 492 #endif
493 ) { 493 ) {
494 bool is_subresource_request = resource_type != ResourceType::MAIN_FRAME; 494 bool is_subresource_request = resource_type != ResourceType::MAIN_FRAME;
495 content::ResourceThrottle* throttle = 495 content::ResourceThrottle* throttle =
496 SafeBrowsingResourceThrottleFactory::Create(request, 496 SafeBrowsingResourceThrottleFactory::Create(request,
497 resource_context, 497 resource_context,
498 is_subresource_request, 498 is_subresource_request,
499 safe_browsing_.get()); 499 safe_browsing_.get());
500 if (throttle) 500 if (throttle)
501 throttles->push_back(throttle); 501 throttles->push_back(throttle);
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
731 url_request->GetTotalReceivedBytes())); 731 url_request->GetTotalReceivedBytes()));
732 } 732 }
733 } 733 }
734 734
735 // static 735 // static
736 void ChromeResourceDispatcherHostDelegate:: 736 void ChromeResourceDispatcherHostDelegate::
737 SetExternalProtocolHandlerDelegateForTesting( 737 SetExternalProtocolHandlerDelegateForTesting(
738 ExternalProtocolHandler::Delegate* delegate) { 738 ExternalProtocolHandler::Delegate* delegate) {
739 g_external_protocol_handler_delegate = delegate; 739 g_external_protocol_handler_delegate = delegate;
740 } 740 }
OLDNEW
« chrome/browser/profiles/profile_io_data.cc ('K') | « chrome/browser/profiles/profile_io_data.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698