IOSTips:启动屏后再加个闪屏的方法

在- (BOOL)application:(UIApplication )application didFinishLaunchingWithOptions:(NSDictionary )launchOptions 里添加

cself.window.rootViewController.view.alpha = 0;
UIImageView *splashImageView = [[UIImageView alloc]initWithImage:[UIImage imageNamed:@"splash"]];
[self.window addSubview:splashImageView];
[UIView animateWithDuration:0.7 animations:^{
    self.window.rootViewController.view.alpha = 1.0;
} completion:^(BOOL finished) {
    [addSubview:splashImageView removeFromSuperview];
}];

原文链接

    原文作者:真烦人
    原文地址: https://segmentfault.com/a/1190000002912279
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞