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

Side by Side Diff: ios/web/public/web_state/ui/crw_web_delegate.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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_ 5 #ifndef IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_
6 #define IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_ 6 #define IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #import <UIKit/UIKit.h> 9 #import <UIKit/UIKit.h>
10 #include <vector> 10 #include <vector>
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 - (void)webWillInitiateLoadWithParams: 72 - (void)webWillInitiateLoadWithParams:
73 (web::NavigationManager::WebLoadParams&)params; 73 (web::NavigationManager::WebLoadParams&)params;
74 - (void)webDidUpdateSessionForLoadWithParams: 74 - (void)webDidUpdateSessionForLoadWithParams:
75 (const web::NavigationManager::WebLoadParams&)params 75 (const web::NavigationManager::WebLoadParams&)params
76 wasInitialNavigation:(BOOL)initialNavigation; 76 wasInitialNavigation:(BOOL)initialNavigation;
77 // Called from finishHistoryNavigationFromEntry. 77 // Called from finishHistoryNavigationFromEntry.
78 // TODO(crbug.com/692331): Remove this method and use |DidFinishNavigation|. 78 // TODO(crbug.com/692331): Remove this method and use |DidFinishNavigation|.
79 - (void)webWillFinishHistoryNavigationFromEntry:(CRWSessionEntry*)fromEntry; 79 - (void)webWillFinishHistoryNavigationFromEntry:(CRWSessionEntry*)fromEntry;
80 // --------------------------------------------------------------------- 80 // ---------------------------------------------------------------------
81 81
82 // Called when |webController| wants to open a new window. |URL| is the URL of
83 // the new window; |openerURL| is the URL of the page which requested a window
84 // to be open; |initiatedByUser| is YES if action was caused by the user.
85 // |webController| will not open a window if this method returns nil. This
86 // method can not return |webController|.
87 - (CRWWebController*)webController:(CRWWebController*)webController
88 createWebControllerForURL:(const GURL&)URL
89 openerURL:(const GURL&)openerURL
90 initiatedByUser:(BOOL)initiatedByUser;
91
92 @optional 82 @optional
93 83
94 // Called to ask CRWWebDelegate if |CRWWebController| should open the given URL. 84 // Called to ask CRWWebDelegate if |CRWWebController| should open the given URL.
95 // CRWWebDelegate can intercept the request by returning NO and processing URL 85 // CRWWebDelegate can intercept the request by returning NO and processing URL
96 // in own way. 86 // in own way.
97 - (BOOL)webController:(CRWWebController*)webController 87 - (BOOL)webController:(CRWWebController*)webController
98 shouldOpenURL:(const GURL&)url 88 shouldOpenURL:(const GURL&)url
99 mainDocumentURL:(const GURL&)mainDocumentURL 89 mainDocumentURL:(const GURL&)mainDocumentURL
100 linkClicked:(BOOL)linkClicked; 90 linkClicked:(BOOL)linkClicked;
101 91
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 // Called when a PassKit file is downloaded. |data| should be the data from a 131 // Called when a PassKit file is downloaded. |data| should be the data from a
142 // PassKit file, but this is not guaranteed, and the delegate is responsible for 132 // PassKit file, but this is not guaranteed, and the delegate is responsible for
143 // error handling non PassKit data using -[PKPass initWithData:error:]. If the 133 // error handling non PassKit data using -[PKPass initWithData:error:]. If the
144 // download does not successfully complete, |data| will be nil. 134 // download does not successfully complete, |data| will be nil.
145 - (void)webController:(CRWWebController*)webController 135 - (void)webController:(CRWWebController*)webController
146 didLoadPassKitObject:(NSData*)data; 136 didLoadPassKitObject:(NSData*)data;
147 137
148 @end 138 @end
149 139
150 #endif // IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_ 140 #endif // IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698