我有一个 Html5 视频播放器:
<video
video id="videoObj" class="video-js vjs-default-skin center" webkit-playsinline autobuffer preload="auto" poster="http://SomePoster.png">
{VideoFiles}
</video>
当互联网连接不好时(在 iOS 设备上播放视频,在 uiWebView 上),视频停止播放。我尝试在此处和此处获取一个事件,但没有一个被触发。
我这里有两个问题:
- 我希望视频在互联网连接不良/丢失时自动恢复播放/缓冲。
- I would expect an event telling me that the video is paused because of internet connection problems.
Am I missing some attributes for html5 video that could help me? (by the way, as a (bad) workaround I am checking the video's currentTime every second. If I see that it is equal to the last state, I know that the video is stuck and I fires the "play" event, in order to resume playing the video.)
Edit: I do not show the video toolbar on the video, so the user cannot resume the video by himself