OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef IOS_WEB_PUBLIC_WEB_STATE_CRW_WEB_VIEW_PROXY_H_ |
| 6 #define IOS_WEB_PUBLIC_WEB_STATE_CRW_WEB_VIEW_PROXY_H_ |
| 7 |
| 8 #import <UIKit/UIKit.h> |
| 9 |
| 10 #include "ios/web/public/web_view_type.h" |
| 11 |
| 12 @class CRWWebViewScrollViewProxy; |
| 13 |
| 14 // Provides an interface for embedders to access the WebState's UIWebView in a |
| 15 // limited and controlled manner. |
| 16 @protocol CRWWebViewProxy<NSObject> |
| 17 |
| 18 // The UIWebView's bounding rectangle (relative to its parent). |
| 19 @property(readonly, assign) CGRect bounds; |
| 20 |
| 21 // A Boolean value indicating whether web content can programmatically display |
| 22 // the keyboard. |
| 23 @property(nonatomic, assign) BOOL keyboardDisplayRequiresUserAction; |
| 24 |
| 25 // Gives the embedder access to the UIWebView's UIScrollView in a limited and |
| 26 // controlled manner. |
| 27 @property(nonatomic, readonly) CRWWebViewScrollViewProxy* scrollViewProxy; |
| 28 |
| 29 // Returns the webview's gesture recognizers. |
| 30 @property(nonatomic, readonly) NSArray* gestureRecognizers; |
| 31 |
| 32 // Retuns the type of the web view this proxy manages. |
| 33 @property(nonatomic, readonly) web::WebViewType webViewType; |
| 34 |
| 35 // Register the given insets for the given caller. |
| 36 - (void)registerInsets:(UIEdgeInsets)insets forCaller:(id)caller; |
| 37 |
| 38 // Unregister the registered insets for the given caller. |
| 39 - (void)unregisterInsetsForCaller:(id)caller; |
| 40 |
| 41 // Wrapper around the addSubview method of the webview. |
| 42 - (void)addSubview:(UIView*)view; |
| 43 |
| 44 // Returns YES if it makes sense to search for text right now. |
| 45 - (BOOL)hasSearchableTextContent; |
| 46 |
| 47 // Returns the currently visible keyboard accessory, or nil. |
| 48 - (UIView*)getKeyboardAccessory; |
| 49 |
| 50 @end |
| 51 |
| 52 #endif // IOS_WEB_PUBLIC_WEB_STATE_CRW_WEB_VIEW_PROXY_H_ |
OLD | NEW |