我播放了电影,但电影结束后无法调用该方法。
我的代码如下:
MPMoviePlayerViewController *pv=[[MPMoviePlayerViewController alloc]initWithContentURL:[NSURL fileURLWithPath:[[arr_videos objectAtIndex:indexPath.row]valueForKey:@"Video_path"]]];
MPMoviePlayerController *pc=[pv moviePlayer];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(moviePlayBackDidFinish:) name:MPMoviePlayerPlaybackDidFinishNotification object:pv];
[self presentViewController:pv animated:YES completion:nil];
[pc prepareToPlay];
[pc play];