OLD | NEW |
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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 - (void)webWillReload; | 51 - (void)webWillReload; |
52 // Called when a page is loaded using loadWithParams. In | 52 // Called when a page is loaded using loadWithParams. In |
53 // |webWillInitiateLoadWithParams|, the |params| argument is non-const so that | 53 // |webWillInitiateLoadWithParams|, the |params| argument is non-const so that |
54 // the delegate can make changes if necessary. | 54 // the delegate can make changes if necessary. |
55 // TODO(rohitrao): This is not a great API. Clean it up. | 55 // TODO(rohitrao): This is not a great API. Clean it up. |
56 - (void)webWillInitiateLoadWithParams: | 56 - (void)webWillInitiateLoadWithParams: |
57 (web::NavigationManager::WebLoadParams&)params; | 57 (web::NavigationManager::WebLoadParams&)params; |
58 - (void)webDidUpdateSessionForLoadWithParams: | 58 - (void)webDidUpdateSessionForLoadWithParams: |
59 (const web::NavigationManager::WebLoadParams&)params | 59 (const web::NavigationManager::WebLoadParams&)params |
60 wasInitialNavigation:(BOOL)initialNavigation; | 60 wasInitialNavigation:(BOOL)initialNavigation; |
| 61 // Called from finishHistoryNavigationFromEntry. |
| 62 // TODO(crbug.com/692331): Remove this method and use |DidFinishNavigation|. |
| 63 - (void)webWillFinishHistoryNavigation; |
61 | 64 |
62 @optional | 65 @optional |
63 | 66 |
64 // Called to ask CRWWebDelegate if |CRWWebController| should open the given URL. | 67 // Called to ask CRWWebDelegate if |CRWWebController| should open the given URL. |
65 // CRWWebDelegate can intercept the request by returning NO and processing URL | 68 // CRWWebDelegate can intercept the request by returning NO and processing URL |
66 // in own way. | 69 // in own way. |
67 - (BOOL)webController:(CRWWebController*)webController | 70 - (BOOL)webController:(CRWWebController*)webController |
68 shouldOpenURL:(const GURL&)url | 71 shouldOpenURL:(const GURL&)url |
69 mainDocumentURL:(const GURL&)mainDocumentURL | 72 mainDocumentURL:(const GURL&)mainDocumentURL |
70 linkClicked:(BOOL)linkClicked; | 73 linkClicked:(BOOL)linkClicked; |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 // Called when a PassKit file is downloaded. |data| should be the data from a | 114 // Called when a PassKit file is downloaded. |data| should be the data from a |
112 // PassKit file, but this is not guaranteed, and the delegate is responsible for | 115 // PassKit file, but this is not guaranteed, and the delegate is responsible for |
113 // error handling non PassKit data using -[PKPass initWithData:error:]. If the | 116 // error handling non PassKit data using -[PKPass initWithData:error:]. If the |
114 // download does not successfully complete, |data| will be nil. | 117 // download does not successfully complete, |data| will be nil. |
115 - (void)webController:(CRWWebController*)webController | 118 - (void)webController:(CRWWebController*)webController |
116 didLoadPassKitObject:(NSData*)data; | 119 didLoadPassKitObject:(NSData*)data; |
117 | 120 |
118 @end | 121 @end |
119 | 122 |
120 #endif // IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_ | 123 #endif // IOS_WEB_PUBLIC_WEB_STATE_UI_CRW_WEB_DELEGATE_H_ |
OLD | NEW |