]> git.saurik.com Git - winterboard.git/blobdiff - Application.mm
Do not attempt to support @1x themes.
[winterboard.git] / Application.mm
index 4bfef618c3040e1a73756a2d019de5edc64a6006..f033c3f5395344c144ed07e971f7c0b6d1f16835 100644 (file)
@@ -46,6 +46,9 @@
 #import <Preferences/PSListController.h>
 #import <Preferences/PSSpecifier.h>
 
+#include <substrate.h>
+#include <mach-o/dyld.h>
+
 static NSBundle *wbSettingsBundle;
 static Class $WBSettingsController;
 
@@ -181,9 +184,17 @@ static Class $WBSettingsController;
 
 @end
 
+MSHook(int32_t, NSVersionOfLinkTimeLibrary, const char *name) {
+    if (strcmp(name, "UIKit") == 0)
+        return 0x6400000;
+    return _NSVersionOfLinkTimeLibrary(name);
+}
+
 int main(int argc, char *argv[]) {
     NSAutoreleasePool *pool( [[NSAutoreleasePool alloc] init]);
 
+    MSHookFunction(NSVersionOfLinkTimeLibrary, MSHake(NSVersionOfLinkTimeLibrary));
+
     int value = UIApplicationMain(argc, argv, @"WBApplication", @"WBApplication");
 
     [pool release];