Created
December 9, 2010 02:05
-
-
Save marshluca/734226 to your computer and use it in GitHub Desktop.
Splash in iOS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. 将你需要的splash界面的图片,存成Default.png | |
2. 在XXXAppDelegate.m程序中,插入如下代码: | |
- (BOOL)application:(UIApplication *)application | |
didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { | |
//–insert a delay of 5 seconds before the splash screen disappears– | |
[NSThread sleepForTimeInterval:5.0]; | |
// Override point for customization after application launch. | |
// Add the view controller’s view to the window and display. | |
[window addSubview:viewController.view]; | |
[window makeKeyAndVisible]; | |
return YES; | |
} | |
这样splash页面就停留5秒后,消失了。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment