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

Unified Diff: content/browser/frame_host/navigator_impl.cc

Issue 988953003: OOPIF: Fix cross-process navigations in new windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix spacing Created 5 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/frame_host/navigator_impl.cc
diff --git a/content/browser/frame_host/navigator_impl.cc b/content/browser/frame_host/navigator_impl.cc
index 72f9f8702c8fa0509b62e2bbdbf6a67661c0bf9e..c5b547a6336feb77368405849f32496212ed9d25 100644
--- a/content/browser/frame_host/navigator_impl.cc
+++ b/content/browser/frame_host/navigator_impl.cc
@@ -620,11 +620,18 @@ void NavigatorImpl::RequestTransferURL(
}
int64 frame_tree_node_id = -1;
+
+ // Send the navigation to the current FrameTreeNode if it's destined for a
+ // subframe in the current tab. We'll assume it's for the main frame
+ // (possibly of a new or different WebContents) otherwise.
if (base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kSitePerProcess)) {
+ switches::kSitePerProcess) &&
+ disposition == CURRENT_TAB &&
+ render_frame_host->GetParent()) {
frame_tree_node_id =
render_frame_host->frame_tree_node()->frame_tree_node_id();
}
+
OpenURLParams params(
dest_url, referrer, frame_tree_node_id, disposition, page_transition,
true /* is_renderer_initiated */);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698