]> git.saurik.com Git - winterboard.git/blobdiff - Application.mm
Factor $getScale$() out to a separate function.
[winterboard.git] / Application.mm
index b09de36615b953ae0787bad1a7ff8b9492c785bc..4bfef618c3040e1a73756a2d019de5edc64a6006 100644 (file)
@@ -39,6 +39,8 @@
 #import <CoreGraphics/CGGeometry.h>
 #import <UIKit/UIKit.h>
 
+#include <objc/objc-runtime.h>
+
 #import <Preferences/PSRootController.h>
 #import <Preferences/PSViewController.h>
 #import <Preferences/PSListController.h>
@@ -134,13 +136,13 @@ static Class $WBSettingsController;
     }
 }
 
-- (id) _popController {
+- (void) _popController {
     // Pop the last controller = exit the application.
     // The only time the last controller should pop is when the user taps Respring/Cancel.
     // Which only gets displayed if the user has made changes.
     if ([self topViewController] == _rootListController)
         [[UIApplication sharedApplication] terminateWithSuccess];
-    return [super _popController];
+    [super _popController];
 }
 
 @end
@@ -168,7 +170,7 @@ static Class $WBSettingsController;
     $WBSettingsController = [wbSettingsBundle principalClass];
 
     CGRect applicationFrame(([UIDevice instancesRespondToSelector:@selector(isWildcat)]
-                         && [[UIDevice currentDevice] isWildcat])
+                         && [[UIDevice currentDevice] isWildcat]) || objc_getClass("UIStatusBar") != nil
                           ? [UIScreen mainScreen].bounds
                           : [UIScreen mainScreen].applicationFrame);
     UIWindow *window([[UIWindow alloc] initWithFrame:applicationFrame]);