是否可以将 UIActivityIndicator 添加到我的应用程序的启动画面?
我在 delegate.m 文件中使用以下代码,但它对我不起作用..
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
// Override point for customization after application launch.
[NSThread sleepForTimeInterval:5.0]; //for running splash screen more time
UIActivityIndicatorView *spinner = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:UIActivityIndicatorViewStyleWhiteLarge];
spinner.center = CGPointMake(139.5, 75.5); // .5 so it doesn't blur
[self.view addSubview:spinner];
[spinner performSelector:@selector(removeFromSuperview) withObject:nil afterDelay:1.0];
return YES;
}
请帮我