我有MPMoviePlayerViewController。 ViewController总是以动画方式解散。我想以“没有动画”的方式解雇它。我怎么能这样做?
NSURL *url = [NSURL fileURLWithPath:filePath];
moviePlayer = [[MPMoviePlayerViewController alloc] initWithContentURL:url];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayBackDidFinish:) name:MPMoviePlayerPlaybackDidFinishNotification object:nil];
[self presentViewController:moviePlayer animated:NO completion:nil];
[moviePlayer.moviePlayer play];
- (void) moviePlayBackDidFinish:(NSNotification*)notification
{
[moviePlayer.moviePlayer stop];
[self dismissViewControllerAnimated:NO completion:nil];
}
目前,根据我的尝试,所有的解雇都是动画的,我不知道为什么。