summaryrefslogtreecommitdiff
path: root/CyteKit/WebView.mm
diff options
context:
space:
mode:
authorJay Freeman (saurik) <saurik@saurik.com>2011-03-13 13:27:45 -0700
committerJay Freeman (saurik) <saurik@saurik.com>2011-03-14 05:09:09 -0700
commitbaa2fba301cb1561e2c0bbc528027074ce73d692 (patch)
treefeeed4865a1ec5b639d43024e19be918c977ad7d /CyteKit/WebView.mm
parent4339c9efc1097445db0b82b0659ffef3757c675a (diff)
Use a constructor, not +initialize.
Diffstat (limited to 'CyteKit/WebView.mm')
-rw-r--r--CyteKit/WebView.mm6
1 files changed, 3 insertions, 3 deletions
diff --git a/CyteKit/WebView.mm b/CyteKit/WebView.mm
index 363b9cb..3ec751a 100644
--- a/CyteKit/WebView.mm
+++ b/CyteKit/WebView.mm
@@ -355,7 +355,9 @@ static void $UIWebViewWebViewDelegate$webViewClose$(UIWebViewWebViewDelegate *se
[[[self _documentView] webView] reloadFromOrigin:nil];
}
-+ (void) initialize {
+@end
+
+__attribute__((__constructor__)) static void $() {
if (Class $UIWebViewWebViewDelegate = objc_getClass("UIWebViewWebViewDelegate")) {
class_addMethod($UIWebViewWebViewDelegate, @selector(webView:addMessageToConsole:), (IMP) &$UIWebViewWebViewDelegate$webView$addMessageToConsole$, "v16@0:4@8@12");
class_addMethod($UIWebViewWebViewDelegate, @selector(webView:decidePolicyForNewWindowAction:request:newFrameName:decisionListener:), (IMP) &$UIWebViewWebViewDelegate$webView$decidePolicyForNewWindowAction$request$newFrameName$decisionListener$, "v28@0:4@8@12@16@20@24");
@@ -365,5 +367,3 @@ static void $UIWebViewWebViewDelegate$webViewClose$(UIWebViewWebViewDelegate *se
class_addMethod($UIWebViewWebViewDelegate, @selector(webViewClose:), (IMP) &$UIWebViewWebViewDelegate$webViewClose$, "v12@0:4@8");
}
}
-
-@end