停止以MPMoviePlayerViewController的动画方式解散?

时间:2016-01-19 08:13:01

标签: ios objective-c mpmovieplayercontroller

我有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];
}

目前,根据我的尝试,所有的解雇都是动画的,我不知道为什么。

0 个答案:

没有答案
相关问题