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

Unified Diff: ios/web/public/web_state/web_state.h

Issue 2755823002: Moved |openedByDOM| to WebState's CreateParams and public interface. (Closed)
Patch Set: test fix & removed include Created 3 years, 9 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
Index: ios/web/public/web_state/web_state.h
diff --git a/ios/web/public/web_state/web_state.h b/ios/web/public/web_state/web_state.h
index 5010d435b604af0f80bef362f2d8c4d64ebc18d1..d3aedcc8e4c3bd66134cf243258240bfd49c3e50 100644
--- a/ios/web/public/web_state/web_state.h
+++ b/ios/web/public/web_state/web_state.h
@@ -57,7 +57,11 @@ class WebState : public base::SupportsUserData {
explicit CreateParams(web::BrowserState* browser_state);
~CreateParams();
+ // The corresponding BrowserState for the new WebState.
web::BrowserState* browser_state;
+
+ // Whether the WebState is created as the result of a window.open
Eugene But (OOO till 7-30) 2017/03/18 00:33:30 Could you please update the comment: Whether this
kkhorimoto 2017/03/20 22:39:20 Done, although I left out the last sentence since
+ bool created_with_opener;
};
// Parameters for the OpenURL() method.
@@ -231,6 +235,10 @@ class WebState : public base::SupportsUserData {
// Returns Mojo interface registry for this WebState.
virtual service_manager::InterfaceRegistry* GetMojoInterfaceRegistry() = 0;
+ // Returns whether this WebState was created via a call to window.open or by
+ // clicking a link with a blank targer.
Eugene But (OOO till 7-30) 2017/03/18 00:33:30 How about this comment?: Whether this WebState was
kkhorimoto 2017/03/20 22:39:20 Done.
+ virtual bool HasOpener() const = 0;
+
protected:
friend class WebStateObserver;
friend class WebStatePolicyDecider;

Powered by Google App Engine
This is Rietveld 408576698