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

Side by Side Diff: chrome/browser/extensions/chrome_content_browser_client_extensions_part.cc

Issue 2392283005: Reland "Merge of CrossSiteResourceHandler and NavigationResourceThrottle." (Closed)
Patch Set: Added debugging code from issue 2393903002 Created 4 years, 2 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/extensions/chrome_content_browser_client_extensions_par t.h" 5 #include "chrome/browser/extensions/chrome_content_browser_client_extensions_par t.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 10
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 site_instance->GetProcess()->GetID())) 456 site_instance->GetProcess()->GetID()))
457 return true; 457 return true;
458 458
459 // Otherwise, swap BrowsingInstances when transitioning to/from Chrome Web 459 // Otherwise, swap BrowsingInstances when transitioning to/from Chrome Web
460 // Store. 460 // Store.
461 return is_current_url_for_web_store != is_new_url_for_web_store; 461 return is_current_url_for_web_store != is_new_url_for_web_store;
462 } 462 }
463 463
464 // static 464 // static
465 bool ChromeContentBrowserClientExtensionsPart::ShouldSwapProcessesForRedirect( 465 bool ChromeContentBrowserClientExtensionsPart::ShouldSwapProcessesForRedirect(
466 content::ResourceContext* resource_context, 466 content::BrowserContext* browser_context,
467 const GURL& current_url, 467 const GURL& current_url,
468 const GURL& new_url) { 468 const GURL& new_url) {
469 ProfileIOData* io_data = ProfileIOData::FromResourceContext(resource_context);
470 return CrossesExtensionProcessBoundary( 469 return CrossesExtensionProcessBoundary(
471 io_data->GetExtensionInfoMap()->extensions(), 470 ExtensionRegistry::Get(browser_context)->enabled_extensions(),
472 current_url, new_url, false); 471 current_url, new_url, false);
473 } 472 }
474 473
475 // static 474 // static
476 bool ChromeContentBrowserClientExtensionsPart::AllowServiceWorker( 475 bool ChromeContentBrowserClientExtensionsPart::AllowServiceWorker(
477 const GURL& scope, 476 const GURL& scope,
478 const GURL& first_party_url, 477 const GURL& first_party_url,
479 content::ResourceContext* context, 478 content::ResourceContext* context,
480 int render_process_id, 479 int render_process_id,
481 int render_frame_id) { 480 int render_frame_id) {
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 } 692 }
694 } 693 }
695 } 694 }
696 695
697 void ChromeContentBrowserClientExtensionsPart::ResourceDispatcherHostCreated() { 696 void ChromeContentBrowserClientExtensionsPart::ResourceDispatcherHostCreated() {
698 content::ResourceDispatcherHost::Get()->RegisterInterceptor( 697 content::ResourceDispatcherHost::Get()->RegisterInterceptor(
699 "Origin", kExtensionScheme, base::Bind(&OnHttpHeaderReceived)); 698 "Origin", kExtensionScheme, base::Bind(&OnHttpHeaderReceived));
700 } 699 }
701 700
702 } // namespace extensions 701 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698