How can I display a splash screen for longer on an iPhone?

前端 未结 24 1894
滥情空心
滥情空心 2020-11-27 11:37

How can I display a splash screen for a longer period of time than the default time on an iPhone?

24条回答
  •  旧巷少年郎
    2020-11-27 12:22

    What I did is presented a modalview controller in the initial screen and then dissmiss it after several seconds

        - (void)viewDidLoad
    {
        [super viewDidLoad];
        ....
      saSplash = [storyboard instantiateViewControllerWithIdentifier:@"SASplashViewController"];
        saSplash.modalPresentationStyle = UIModalPresentationFullScreen;
        [self presentModalViewController: saSplash animated:NO];
    }
    
    -(void) dismissSASplash {
        [saSplash dismissModalViewControllerAnimated:NO];
    
    }
    

提交回复
热议问题