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

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

Issue 1422333009: OOPIF: History navigations for new child frames. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Improve comment. Created 5 years 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 | « content/browser/frame_host/navigator_impl.cc ('k') | content/common/frame_messages.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/frame_host/render_frame_host_impl.cc
diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc
index 6a3d46e832ccbd68b3db78f562135f5af7762db2..8c878412847822ceef70c26b06c2d92296e96112 100644
--- a/content/browser/frame_host/render_frame_host_impl.cc
+++ b/content/browser/frame_host/render_frame_host_impl.cc
@@ -811,6 +811,17 @@ void RenderFrameHostImpl::OnFrameFocused() {
}
void RenderFrameHostImpl::OnOpenURL(const FrameHostMsg_OpenURL_Params& params) {
+ if (params.is_history_navigation_in_new_child) {
+ DCHECK(SiteIsolationPolicy::UseSubframeNavigationEntries());
+
+ // Try to find a FrameNavigationEntry that matches this frame instead, based
+ // on the frame's unique name. If this can't be found, fall back to the
+ // default params using OpenURL below.
+ if (frame_tree_node_->navigator()->NavigateNewChildFrame(
+ this, params.frame_unique_name))
+ return;
+ }
+
OpenURL(params, GetSiteInstance());
}
« no previous file with comments | « content/browser/frame_host/navigator_impl.cc ('k') | content/common/frame_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698