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

Unified Diff: content/browser/web_contents/web_contents_impl.cc

Issue 2885043004: ABANDONED CL: Make WebContents::Get(Original)Opener return RenderFrameHost* (not WebContents*). (Closed)
Patch Set: Created 3 years, 7 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 | « content/browser/web_contents/web_contents_impl.h ('k') | content/public/browser/web_contents.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/web_contents/web_contents_impl.cc
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc
index d05d180e81614d681074531ddd0b25c44068d803..f74d7ca1513b344cccffa260130142f2121bdc76 100644
--- a/content/browser/web_contents/web_contents_impl.cc
+++ b/content/browser/web_contents/web_contents_impl.cc
@@ -3342,18 +3342,18 @@ bool WebContentsImpl::HasOpener() const {
return GetOpener() != NULL;
}
-WebContentsImpl* WebContentsImpl::GetOpener() const {
+RenderFrameHostImpl* WebContentsImpl::GetOpener() const {
FrameTreeNode* opener_ftn = frame_tree_.root()->opener();
- return opener_ftn ? FromFrameTreeNode(opener_ftn) : nullptr;
+ return opener_ftn ? opener_ftn->current_frame_host() : nullptr;
}
bool WebContentsImpl::HasOriginalOpener() const {
return GetOriginalOpener() != NULL;
}
-WebContents* WebContentsImpl::GetOriginalOpener() const {
+RenderFrameHostImpl* WebContentsImpl::GetOriginalOpener() const {
FrameTreeNode* opener_ftn = frame_tree_.root()->original_opener();
- return opener_ftn ? FromFrameTreeNode(opener_ftn) : nullptr;
+ return opener_ftn ? opener_ftn->current_frame_host() : nullptr;
}
void WebContentsImpl::DidChooseColorInColorChooser(SkColor color) {
« no previous file with comments | « content/browser/web_contents/web_contents_impl.h ('k') | content/public/browser/web_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698