您的位置:首页 > 移动开发 > IOS开发

ios启动动画

2015-07-13 14:06 453 查看
1、在images.xcassets里面加入LaunchImage

2、删掉LaunchScreen.xib

3、在Supporting Files里的info.plist的文件下,移除Launch screen interface file base...

在配置文件Target--->项目名称---->General----->

4、把以上第二行改成以上名字

5、- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {

if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) {

//此行配合plist文件中的View controller-based status bar appearance=NO一起使用,解决状态栏全黑的问题

[application setStatusBarStyle:UIStatusBarStyleLightContent];}

//使启动动画停顿2秒

[NSThread sleepForTimeInterval:2.0];

//使进入界面不为全黑,为白色

self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];

self.window.backgroundColor = [UIColor whiteColor];

[self.window makeKeyAndVisible];

return YES;

}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: