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

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

Issue 2737943003: Moved window opening callback to WebStateDelegate. (Closed)
Patch Set: Self review 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/web_state/web_state_impl.h
diff --git a/ios/web/web_state/web_state_impl.h b/ios/web/web_state/web_state_impl.h
index 21234069cb2fcd2a024d1c149437fc722a6530e0..7a160ed40ba1922acdfb3ae4048c6ec62dcac93a 100644
--- a/ios/web/web_state/web_state_impl.h
+++ b/ios/web/web_state/web_state_impl.h
@@ -253,6 +253,14 @@ class WebStateImpl : public WebState, public NavigationManagerDelegate {
NSString* default_prompt_text,
const DialogClosedCallback& callback);
+ // Instructs the delegate to create a new web state. Called when this WebState
+ // wants to open a new window. |url| is the URL of the new window;
+ // |opener_url| is the URL of the page which requested a window to be open;
+ // |initiated_by_user| is true if action was caused by the user.
+ WebState* CreateNewWebState(const GURL& url,
+ const GURL& opener_url,
+ bool initiated_by_user);
+
// Notifies the delegate that request receives an authentication challenge
// and is unable to respond using cached credentials.
void OnAuthRequired(NSURLProtectionSpace* protection_space,

Powered by Google App Engine
This is Rietveld 408576698