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

Unified Diff: chrome/browser/renderer_host/render_view_host_manager.cc

Issue 126137: Part 1 of merging Extensions and DOMUI (Closed)
Patch Set: add test and rebase Created 11 years, 6 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
Index: chrome/browser/renderer_host/render_view_host_manager.cc
diff --git a/chrome/browser/renderer_host/render_view_host_manager.cc b/chrome/browser/renderer_host/render_view_host_manager.cc
index c0be053bf1f7055f0f57587104fdc85f8907a680..7c4d21928db4af6cbf456b1c8cae377d05d41a60 100644
--- a/chrome/browser/renderer_host/render_view_host_manager.cc
+++ b/chrome/browser/renderer_host/render_view_host_manager.cc
@@ -19,6 +19,7 @@
#include "chrome/common/notification_service.h"
#include "chrome/common/notification_type.h"
#include "chrome/common/render_messages.h"
+#include "chrome/common/url_constants.h"
namespace base {
class WaitableEvent;
@@ -294,6 +295,14 @@ bool RenderViewHostManager::ShouldSwapProcessesForNavigation(
DOMUIFactory::HasDOMUIScheme(new_entry->url()))
return true;
+ // Also, we must switch if one is an extension and the other is not the exact
+ // same extension.
+ if (cur_entry->url().SchemeIs(chrome::kExtensionScheme) ||
+ new_entry->url().SchemeIs(chrome::kExtensionScheme))
+ if (cur_entry->url().GetOrigin() != new_entry->url().GetOrigin())
+ return true;
+
+
return false;
}
« no previous file with comments | « chrome/browser/renderer_host/render_view_host_delegate.h ('k') | chrome/browser/tab_contents/interstitial_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698