-+ (float) defaultWidth {
- return 980;
-}
-
-- (void) webView:(WebView *)sender didReceiveMessage:(NSDictionary *)dictionary {
-#if LogBrowser || ForSaurik
- NSLog(@"Console:%@\n", [dictionary description]);
-#endif
- if ([document_ respondsToSelector:@selector(webView:didReceiveMessage:)])
- [document_ webView:sender didReceiveMessage:dictionary];
-}
-
-- (void) webView:(id)sender willCloseFrame:(id)frame {
- if ([document_ respondsToSelector:@selector(webView:willCloseFrame:)])
- [document_ webView:sender willCloseFrame:frame];
-}
-
-- (void) webView:(id)sender didFinishDocumentLoadForFrame:(id)frame {
- if ([document_ respondsToSelector:@selector(webView:didFinishDocumentLoadForFrame:)])
- [document_ webView:sender didFinishDocumentLoadForFrame:frame];
-}
-
-- (void) webView:(id)sender didFirstLayoutInFrame:(id)frame {
- if ([document_ respondsToSelector:@selector(webView:didFirstLayoutInFrame:)])
- [document_ webView:sender didFirstLayoutInFrame:frame];
-}
-
-- (void) webViewFormEditedStatusHasChanged:(id)changed {
- if ([document_ respondsToSelector:@selector(webViewFormEditedStatusHasChanged:)])
- [document_ webViewFormEditedStatusHasChanged:changed];
-}
-
-- (void) webView:(id)sender formStateDidFocusNode:(id)formState {
- if ([document_ respondsToSelector:@selector(webView:formStateDidFocusNode:)])
- [document_ webView:sender formStateDidFocusNode:formState];
-}
-
-- (void) webView:(id)sender formStateDidBlurNode:(id)formState {
- if ([document_ respondsToSelector:@selector(webView:formStateDidBlurNode:)])
- [document_ webView:sender formStateDidBlurNode:formState];
-}
-
-- (void) webViewDidLayout:(id)sender {
- [document_ webViewDidLayout:sender];
-}
-
-- (void) webView:(id)sender didFirstVisuallyNonEmptyLayoutInFrame:(id)frame {
- [document_ webView:sender didFirstVisuallyNonEmptyLayoutInFrame:frame];
-}
-
-- (void) webView:(id)sender saveStateToHistoryItem:(id)item forFrame:(id)frame {
- [document_ webView:sender saveStateToHistoryItem:item forFrame:frame];
-}
-
-- (void) webView:(id)sender restoreStateFromHistoryItem:(id)item forFrame:(id)frame force:(BOOL)force {
- [document_ webView:sender restoreStateFromHistoryItem:item forFrame:frame force:force];
-}
-
-- (void) webView:(id)sender attachRootLayer:(id)layer {
- [document_ webView:sender attachRootLayer:layer];
-}
-
-- (id) webView:(id)sender plugInViewWithArguments:(id)arguments fromPlugInPackage:(id)package {
- return [document_ webView:sender plugInViewWithArguments:arguments fromPlugInPackage:package];
-}
-
-- (void) webView:(id)sender willShowFullScreenForPlugInView:(id)view {
- [document_ webView:sender willShowFullScreenForPlugInView:view];
-}
-
-- (void) webView:(id)sender didHideFullScreenForPlugInView:(id)view {
- [document_ webView:sender didHideFullScreenForPlugInView:view];
-}
-
-- (void) webView:(id)sender willAddPlugInView:(id)view {
- [document_ webView:sender willAddPlugInView:view];
-}
-
-- (void) webView:(id)sender didObserveDeferredContentChange:(int)change forFrame:(id)frame {
- [document_ webView:sender didObserveDeferredContentChange:change forFrame:frame];
-}
-
-- (void) webViewDidPreventDefaultForEvent:(id)sender {
- [document_ webViewDidPreventDefaultForEvent:sender];
-}
-
-- (void) _setTileDrawingEnabled:(BOOL)enabled {
- //[document_ setTileDrawingEnabled:enabled];
-}
-
-- (void) willStartGesturesInView:(UIView *)view forEvent:(GSEventRef)event {
- [self _setTileDrawingEnabled:NO];
-}
-
-- (void) didFinishGesturesInView:(UIView *)view forEvent:(GSEventRef)event {
- [self _setTileDrawingEnabled:YES];
- [document_ redrawScaledDocument];
-}
-
-- (void) setViewportWidth:(float)width {
- width_ = width != 0 ? width : [[self class] defaultWidth];
- [document_ setViewportSize:CGSizeMake(width_, UIWebViewGrowsAndShrinksToFitHeight) forDocumentTypes:0x10];
-}
-
-- (void) scrollerWillStartDragging:(UIScroller *)scroller {
- [self _setTileDrawingEnabled:NO];
-}
-
-- (void) scrollerDidEndDragging:(UIScroller *)scroller willSmoothScroll:(BOOL)smooth {
- [self _setTileDrawingEnabled:YES];
-}
-
-- (void) scrollerDidEndDragging:(UIScroller *)scroller {
- [self _setTileDrawingEnabled:YES];
-}
-