]> git.saurik.com Git - cydia.git/blame - UICaboodle/BrowserView.h
Commit (chpwn): uiviewcontroller-final.patch
[cydia.git] / UICaboodle / BrowserView.h
CommitLineData
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
b5e7eebb 43- (UCViewController *) pageForURL:(NSURL *)url hasTag:(int *)tag;
43f3d7f6 44@end
ab398adf 45
b5e7eebb 46@interface BrowserView : UCViewController {
ab398adf 47 UIScroller *scroller_;
ebffe5ce 48 UIWebDocumentView *document_;
ab398adf 49 UIProgressIndicator *indicator_;
facbc56d 50 IndirectDelegate *indirect_;
0ce617c8 51 NSURLAuthenticationChallenge *challenge_;
fe468f45
JF
52
53 bool error_;
0c7c9052 54 NSURLRequest *request_;
ab398adf 55
9fe5e5f8 56 NSNumber *confirm_;
0dceb29b 57 NSNumber *sensitive_;
ab398adf 58 NSString *title_;
caa427d1 59 NSMutableSet *loading_;
ab398adf 60 bool reloading_;
a0376fc1 61
9fe5e5f8
JF
62 NSString *button_;
63 NSString *style_;
caa427d1 64
9fe5e5f8 65 WebScriptObject *function_;
12b59862 66 WebScriptObject *closer_;
caa427d1
JF
67 WebScriptObject *special_;
68 WebScriptObject *finish_;
9fe5e5f8 69
a0376fc1 70 bool pushed_;
3e9c9e85
JF
71
72 float width_;
73 bool popup_;
eb35c522
JF
74
75 CGSize size_;
76 bool editing_;
245cce8a
JF
77
78 Class class_;
ab398adf
JF
79}
80
ea173384
JF
81+ (void) _initialize;
82
0ce617c8
JF
83- (void) alertSheet:(UIActionSheet *)sheet buttonClicked:(int)button;
84
ab398adf
JF
85- (void) loadURL:(NSURL *)url cachePolicy:(NSURLRequestCachePolicy)policy;
86- (void) loadURL:(NSURL *)url;
87
88- (void) loadRequest:(NSURLRequest *)request;
89- (void) reloadURL;
12b59862 90- (bool) isLoading;
ab398adf 91
caa427d1
JF
92- (void) fixScroller;
93
ab398adf 94- (WebView *) webView;
1b1b3f4a 95- (UIWebDocumentView *) documentView;
ab398adf 96
b5e7eebb
GP
97- (id) init;
98- (id) initWithWidth:(float)width;
99- (id) initWithWidth:(float)width ofClass:(Class)_class;
ab398adf 100
caa427d1
JF
101- (NSString *) stringByEvaluatingJavaScriptFromString:(NSString *)script;
102- (void) callFunction:(WebScriptObject *)function;
103
7d2ac47f 104- (void) webView:(WebView *)sender didFinishLoadForFrame:(WebFrame *)frame;
c390d3ab 105- (void) webView:(WebView *)sender didClearWindowObject:(WebScriptObject *)window forFrame:(WebFrame *)frame;
7d2ac47f 106
43f3d7f6
JF
107- (NSURLRequest *) webView:(WebView *)sender resource:(id)identifier willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)redirectResponse fromDataSource:(WebDataSource *)source;
108
3e9c9e85 109+ (float) defaultWidth;
eb35c522 110- (void) setViewportWidth:(float)width;
3e9c9e85 111
caa427d1
JF
112- (void) setButtonImage:(NSString *)button withStyle:(NSString *)style toFunction:(id)function;
113- (void) setButtonTitle:(NSString *)button withStyle:(NSString *)style toFunction:(id)function;
114- (void) setFinishHook:(id)function;
115- (void) setPopupHook:(id)function;
116
bd0a4099
JF
117- (id) _rightButtonTitle;
118
0dceb29b
JF
119- (bool) promptForSensitive:(NSString *)name;
120- (bool) allowSensitiveRequests;
121
b5e7eebb 122@end