扫码关注官方订阅号
这是一个用UIWebview加载的网页视频,然后在iPhone 上面播放以后就会出现iphone 的导航,我想得到done的点击事件怎么能得到呢?
人生最曼妙的风景,竟是内心的淡定与从容!
首先你要添加一个通知[notificationCenter addObserver:self selector:@selector(mediaPlayerPlaybackFinished:) name:MPMoviePlayerPlaybackDidFinishNotification object:self.moviePlayer];
/**
播放完成*
@param notification 通知对象*/
-(void)mediaPlayerPlaybackFinished:(NSNotification *)notification{
NSLog(@"播放完成.%li",(long)self.moviePlayer.playbackState); // 你的操作
}
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
首先你要添加一个通知
[notificationCenter addObserver:self selector:@selector(mediaPlayerPlaybackFinished:) name:MPMoviePlayerPlaybackDidFinishNotification object:self.moviePlayer];
/**
播放完成
*
@param notification 通知对象
*/
-(void)mediaPlayerPlaybackFinished:(NSNotification *)notification{
}