动态加载StoryBoard的代码如下:
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
UIStoryboard * storyBoard = [UIStoryboard storyboardWithName:@"First" bundle:[NSBundle mainBundle]];
self.window.rootViewController = [storyBoard instantiateInitialViewController];
self.window.backgroundColor = [UIColor whiteColor];
[self.window makeKeyAndVisible];
网友评论