(iOS)动画切换window的根控制器

// options是动画选项[UIViewtransitionWithView:[UIApplicationsharedApplication].keyWindow duration:0.5f options:UIViewAnimationOptionTransitionCrossDissolveanimations:^{BOOLoldState = [UIViewareAnimationsEnabled]; [UIViewsetAnimationsEnabled:NO]; [UIApplicationsharedApplication].keyWindow.rootViewController = [RootViewController new]; [UIViewsetAnimationsEnabled:oldState]; } completion:^(BOOLfinished) { }];

你可能感兴趣的:((iOS)动画切换window的根控制器)