]>
Commit | Line | Data |
---|---|---|
ab398adf JF |
1 | #import "ResetView.h" |
2 | ||
22f8bed9 JF |
3 | #include <WebKit/DOMCSSPrimitiveValue.h> |
4 | #include <WebKit/DOMCSSStyleDeclaration.h> | |
5 | #include <WebKit/DOMDocument.h> | |
6 | #include <WebKit/DOMHTMLBodyElement.h> | |
7 | #include <WebKit/DOMNodeList.h> | |
8 | #include <WebKit/DOMRGBColor.h> | |
9 | ||
10 | #include <WebKit/WebFrame.h> | |
11 | #include <WebKit/WebPolicyDelegate.h> | |
12 | #include <WebKit/WebPreferences.h> | |
13 | #include <WebKit/WebScriptObject.h> | |
14 | ||
15 | #import <WebKit/WebView.h> | |
16 | #import <WebKit/WebView-WebPrivate.h> | |
17 | ||
18 | #include <WebCore/Page.h> | |
19 | #include <WebCore/Settings.h> | |
20 | ||
21 | #import <JavaScriptCore/JavaScriptCore.h> | |
22 | ||
ab398adf JF |
23 | @class NSMutableArray; |
24 | @class NSString; | |
25 | @class NSURL; | |
26 | @class NSURLRequest; | |
27 | ||
28 | @class UIProgressIndicator; | |
29 | @class UIScroller; | |
facbc56d | 30 | @class UIDocumentWebView; |
ab398adf | 31 | |
a9543575 JF |
32 | @class WebView; |
33 | ||
ab398adf | 34 | @class Database; |
facbc56d | 35 | @class IndirectDelegate; |
43f3d7f6 JF |
36 | |
37 | @interface WebScriptObject (UICaboodle) | |
38 | - (unsigned) count; | |
39 | - (id) objectAtIndex:(unsigned)index; | |
40 | @end | |
41 | ||
42 | @protocol BrowserViewDelegate | |
43 | - (RVPage *) pageForURL:(NSURL *)url hasTag:(int *)tag; | |
44 | @end | |
ab398adf | 45 | |
12b59862 JF |
46 | @interface BrowserView : RVPage < |
47 | RVBookHook | |
48 | > { | |
ab398adf | 49 | UIScroller *scroller_; |
facbc56d | 50 | UIWebDocumentView *webview_; |
ab398adf | 51 | UIProgressIndicator *indicator_; |
facbc56d | 52 | IndirectDelegate *indirect_; |
0ce617c8 | 53 | NSURLAuthenticationChallenge *challenge_; |
fe468f45 JF |
54 | |
55 | bool error_; | |
0c7c9052 | 56 | NSURLRequest *request_; |
ab398adf | 57 | |
9fe5e5f8 | 58 | NSNumber *confirm_; |
0dceb29b | 59 | NSNumber *sensitive_; |
ab398adf | 60 | NSString *title_; |
caa427d1 | 61 | NSMutableSet *loading_; |
ab398adf | 62 | bool reloading_; |
a0376fc1 | 63 | |
9fe5e5f8 JF |
64 | NSString *button_; |
65 | NSString *style_; | |
caa427d1 | 66 | |
9fe5e5f8 | 67 | WebScriptObject *function_; |
12b59862 | 68 | WebScriptObject *closer_; |
caa427d1 JF |
69 | WebScriptObject *special_; |
70 | WebScriptObject *finish_; | |
9fe5e5f8 | 71 | |
a0376fc1 | 72 | bool pushed_; |
3e9c9e85 JF |
73 | |
74 | float width_; | |
75 | bool popup_; | |
eb35c522 JF |
76 | |
77 | CGSize size_; | |
78 | bool editing_; | |
245cce8a JF |
79 | |
80 | Class class_; | |
ab398adf JF |
81 | } |
82 | ||
ea173384 JF |
83 | + (void) _initialize; |
84 | ||
0ce617c8 JF |
85 | - (void) alertSheet:(UIActionSheet *)sheet buttonClicked:(int)button; |
86 | ||
ab398adf JF |
87 | - (void) loadURL:(NSURL *)url cachePolicy:(NSURLRequestCachePolicy)policy; |
88 | - (void) loadURL:(NSURL *)url; | |
89 | ||
90 | - (void) loadRequest:(NSURLRequest *)request; | |
91 | - (void) reloadURL; | |
12b59862 | 92 | - (bool) isLoading; |
ab398adf | 93 | |
caa427d1 JF |
94 | - (void) fixScroller; |
95 | ||
ab398adf | 96 | - (WebView *) webView; |
1b1b3f4a | 97 | - (UIWebDocumentView *) documentView; |
ab398adf | 98 | |
3160e5f0 | 99 | - (id) initWithBook:(RVBook *)book; |
3e9c9e85 | 100 | - (id) initWithBook:(RVBook *)book forWidth:(float)width; |
245cce8a | 101 | - (id) initWithBook:(RVBook *)book forWidth:(float)width ofClass:(Class)_class; |
ab398adf | 102 | |
caa427d1 JF |
103 | - (NSString *) stringByEvaluatingJavaScriptFromString:(NSString *)script; |
104 | - (void) callFunction:(WebScriptObject *)function; | |
105 | ||
7d2ac47f | 106 | - (void) webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame; |
c390d3ab | 107 | - (void) webView:(WebView *)sender didClearWindowObject:(WebScriptObject *)window forFrame:(WebFrame *)frame; |
7d2ac47f | 108 | |
43f3d7f6 JF |
109 | - (NSURLRequest *) webView:(WebView *)sender resource:(id)identifier willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)redirectResponse fromDataSource:(WebDataSource *)source; |
110 | ||
3e9c9e85 | 111 | + (float) defaultWidth; |
eb35c522 | 112 | - (void) setViewportWidth:(float)width; |
3e9c9e85 | 113 | |
caa427d1 JF |
114 | - (void) setButtonImage:(NSString *)button withStyle:(NSString *)style toFunction:(id)function; |
115 | - (void) setButtonTitle:(NSString *)button withStyle:(NSString *)style toFunction:(id)function; | |
116 | - (void) setFinishHook:(id)function; | |
117 | - (void) setPopupHook:(id)function; | |
118 | ||
bd0a4099 JF |
119 | - (id) _rightButtonTitle; |
120 | ||
0dceb29b JF |
121 | - (bool) promptForSensitive:(NSString *)name; |
122 | - (bool) allowSensitiveRequests; | |
123 | ||
ab398adf | 124 | @end |