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

Unified Diff: content/renderer/render_frame_proxy.cc

Issue 692973005: Pass origin information for remote frame creation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address review feedback; send origins with DidCommitProvisionalLoad Created 6 years, 1 month 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: content/renderer/render_frame_proxy.cc
diff --git a/content/renderer/render_frame_proxy.cc b/content/renderer/render_frame_proxy.cc
index 6b8c760fe24ceec2acadee22b830d4cc26d0a375..d2ab68a4524f8ddec428e8ffbb9419d6721f06df 100644
--- a/content/renderer/render_frame_proxy.cc
+++ b/content/renderer/render_frame_proxy.cc
@@ -9,12 +9,14 @@
#include "base/lazy_instance.h"
#include "content/child/webmessageportchannel_impl.h"
#include "content/common/frame_messages.h"
+#include "content/common/frame_replication_state.h"
#include "content/common/swapped_out_messages.h"
#include "content/common/view_messages.h"
#include "content/renderer/child_frame_compositing_helper.h"
#include "content/renderer/render_frame_impl.h"
#include "content/renderer/render_thread_impl.h"
#include "content/renderer/render_view_impl.h"
+#include "third_party/WebKit/public/platform/WebString.h"
#include "third_party/WebKit/public/web/WebLocalFrame.h"
#include "third_party/WebKit/public/web/WebUserGestureIndicator.h"
#include "third_party/WebKit/public/web/WebView.h"
@@ -54,7 +56,8 @@ RenderFrameProxy* RenderFrameProxy::CreateProxyToReplaceFrame(
RenderFrameProxy* RenderFrameProxy::CreateFrameProxy(
int routing_id,
int parent_routing_id,
- int render_view_routing_id) {
+ int render_view_routing_id,
+ const FrameReplicationState& replicated_state) {
scoped_ptr<RenderFrameProxy> proxy(
new RenderFrameProxy(routing_id, MSG_ROUTING_NONE));
RenderViewImpl* render_view = NULL;
@@ -74,6 +77,10 @@ RenderFrameProxy* RenderFrameProxy::CreateFrameProxy(
render_view = parent->render_view();
}
+ // Initialize the WebRemoteFrame with the security origin and other
+ // replicated information.
+ RenderFrameImpl::SetReplicatedState(web_frame, replicated_state);
+
proxy->Init(web_frame, render_view);
return proxy.release();

Powered by Google App Engine
This is Rietveld 408576698