IOS应用启动时渐变等待

  1. - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions  
  2. {  
  3.     self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];  
  4.     [UIApplication sharedApplication].statusBarHidden = YES;  
  5.       
  6.       
  7.     UIImageView *splashScreen = [[UIImageView alloc] initWithFrame:self.window.bounds];  
  8.     splashScreen.image = [UIImage imageNamed:@"程序进入图.png"];  
  9.     [self.window addSubview:splashScreen];  
  10.       
  11.     [UIView animateWithDuration:5.0 animations:^{  
  12.         CATransform3D transform = CATransform3DMakeScale(0.50.51.0);  
  13.         splashScreen.layer.transform = transform;  
  14.         splashScreen.alpha = 0.8;  
  15.         MyLog(@"111");  
  16.     } completion:^(BOOL finished) {  
  17.         [splashScreen removeFromSuperview];  
  18.         MyLog(@"222");  
  19.         self.window.rootViewController = [[LoginViewController alloc]init];  
  20.         self.window.backgroundColor = [UIColor whiteColor];  
  21.            }];  
  22.       
  23.     _netRequest = [[NetRequest alloc] init];  
  24.       
  25.     [self.window makeKeyAndVisible];  
  26.     return YES;  
  27. }  

你可能感兴趣的:(ios,应用,启动图,时间渐变)