OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_WEB_STATE_H_ | 5 #ifndef IOS_WEB_PUBLIC_WEB_STATE_WEB_STATE_H_ |
6 #define IOS_WEB_PUBLIC_WEB_STATE_WEB_STATE_H_ | 6 #define IOS_WEB_PUBLIC_WEB_STATE_WEB_STATE_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 // Resizes |content_view| to the content area's size and adds it to the | 190 // Resizes |content_view| to the content area's size and adds it to the |
191 // hierarchy. A navigation will remove the view from the hierarchy. | 191 // hierarchy. A navigation will remove the view from the hierarchy. |
192 virtual void ShowTransientContentView(CRWContentView* content_view) = 0; | 192 virtual void ShowTransientContentView(CRWContentView* content_view) = 0; |
193 | 193 |
194 // Returns true if a WebInterstitial is currently displayed. | 194 // Returns true if a WebInterstitial is currently displayed. |
195 virtual bool IsShowingWebInterstitial() const = 0; | 195 virtual bool IsShowingWebInterstitial() const = 0; |
196 | 196 |
197 // Returns the currently visible WebInterstitial if one is shown. | 197 // Returns the currently visible WebInterstitial if one is shown. |
198 virtual WebInterstitial* GetWebInterstitial() const = 0; | 198 virtual WebInterstitial* GetWebInterstitial() const = 0; |
199 | 199 |
200 // Returns the unique ID to use with web::CertStore. | |
201 virtual int GetCertGroupId() const = 0; | |
202 | |
203 // Callback used to handle script commands. | 200 // Callback used to handle script commands. |
204 // The callback must return true if the command was handled, and false | 201 // The callback must return true if the command was handled, and false |
205 // otherwise. | 202 // otherwise. |
206 // In particular the callback must return false if the command is unexpected | 203 // In particular the callback must return false if the command is unexpected |
207 // or ill-formatted. | 204 // or ill-formatted. |
208 // The first parameter is the content of the command, the second parameter is | 205 // The first parameter is the content of the command, the second parameter is |
209 // the URL of the page, and the third parameter is a bool indicating if the | 206 // the URL of the page, and the third parameter is a bool indicating if the |
210 // user is currently interacting with the page. | 207 // user is currently interacting with the page. |
211 typedef base::Callback<bool(const base::DictionaryValue&, const GURL&, bool)> | 208 typedef base::Callback<bool(const base::DictionaryValue&, const GURL&, bool)> |
212 ScriptCommandCallback; | 209 ScriptCommandCallback; |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 | 265 |
269 // Returns a WeakPtr<WebState> to the current WebState. Must remain private | 266 // Returns a WeakPtr<WebState> to the current WebState. Must remain private |
270 // and only call must be in WebStateWeakPtrFactory. Please consult that class | 267 // and only call must be in WebStateWeakPtrFactory. Please consult that class |
271 // for more details. Remove as part of http://crbug.com/556736. | 268 // for more details. Remove as part of http://crbug.com/556736. |
272 virtual base::WeakPtr<WebState> AsWeakPtr() = 0; | 269 virtual base::WeakPtr<WebState> AsWeakPtr() = 0; |
273 }; | 270 }; |
274 | 271 |
275 } // namespace web | 272 } // namespace web |
276 | 273 |
277 #endif // IOS_WEB_PUBLIC_WEB_STATE_WEB_STATE_H_ | 274 #endif // IOS_WEB_PUBLIC_WEB_STATE_WEB_STATE_H_ |
OLD | NEW |