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 4a016945ec23b1bf395fbb8ff3b46823ca0ce1a9..ec98d5e4681caf22f56ed61256a51ec939cca921 100644 |
--- a/content/browser/frame_host/render_frame_host_impl.cc |
+++ b/content/browser/frame_host/render_frame_host_impl.cc |
@@ -313,6 +313,15 @@ GURL RenderFrameHostImpl::GetLastCommittedURL() { |
return frame_tree_node_->current_url(); |
} |
+url::Origin RenderFrameHostImpl::GetLastCommittedOrigin() { |
+ // Origin is stored per-FTN, so it's incorrect to call for a non-current RFH. |
+ if (this != frame_tree_node_->current_frame_host()) { |
+ NOTREACHED() << "Origin information is tracked only for the current host."; |
+ return url::Origin(); |
Charlie Reis
2015/11/24 21:00:42
Sanity check: Since there aren't callers yet, do w
ncarter (slow)
2015/11/24 22:07:33
Switched to a CHECK based on our face-to-face disc
|
+ } |
+ return frame_tree_node_->current_origin(); |
+} |
+ |
gfx::NativeView RenderFrameHostImpl::GetNativeView() { |
RenderWidgetHostView* view = render_view_host_->GetWidget()->GetView(); |
if (!view) |