-(BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary*)launchOptions {
{
CGSize iosScreenSize = [[UIScreen mainScreen] bounds].size;
if (iosScreenSize.height == 667) {
UIStoryboard *iPhone6 = [UIStoryboard storyboardWithName:@"iPhone6" bundle:nil];
UIViewController *initialViewController =[iPhone6 instantiateInitialViewController];
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen]bounds]];
self.window.rootViewController = initialViewController;
[self.window makeKeyAndVisible];
}
return YES;
}
return YES;
}
That is all i added in AppDelegate.m. Im using Xcode 6.1. I did this because i'm not using auto layout so I created a separate ViewController and called it iPhone6.h and iPhone6.m and a created a storyboard for it calling it iPhone6. I've connected the iPhone6 storyboard to iPhone 6.h and .m so i don't understand why when i'm loading the iPhone6 simulator I automatically get the "Application windows are expected to have a root view controller at the end of application launch" error. Why am I getting it?