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

Unified Diff: content/public/browser/web_contents.h

Issue 2661403003: Track the original opener of a webcontents so we can rely on it for popups (Closed)
Patch Set: updates Created 3 years, 11 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.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/browser/web_contents.h
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
index 98c79247aec25c919a5593a67da809b1bf7f4684..8575d4f2e28e5818b72e480fa006abb7ad6feeb2 100644
--- a/content/public/browser/web_contents.h
+++ b/content/public/browser/web_contents.h
@@ -638,6 +638,14 @@ class WebContents : public PageNavigator,
// Returns the opener if HasOpener() is true, or nullptr otherwise.
virtual WebContents* GetOpener() const = 0;
+ // Returns true if this WebContents was opened by another WebContents, even
+ // if the opener was suppressed.
Avi (use Gerrit) 2017/02/03 19:26:33 ... even if the JavaScript opener was suppressed..
+ virtual bool HasOriginalOpener() const = 0;
+
+ // Returns the original opener if HasOriginalOpener() is true, or nullptr
+ // otherwise.
+ virtual WebContents* GetOriginalOpener() const = 0;
+
typedef base::Callback<void(
int, /* id */
int, /* HTTP status code */
« no previous file with comments | « content/browser/web_contents/web_contents_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698