Since the new update from the chrome browser earlier this year, we have the problem that our Videos in our Hypefile don’t stop playing after changing the scene. We tried out various things as reset videos and stop videos.
This is the structure of the document:
On a scene (overview) we have 6 Images which are linked to each new slide with a video on it. The Video needs to be played automatically. On the swipe left and swipe right we have a function wich brings you either back to the overview or to an other slides which leads you also to one of the videos depending on where you came from. All of this works. But due to this new chrome-videoplayer the “video_stop” functions seem to be not working anymore after swiping. When loading the new scene after swiping, the video starts playing again in the background. The reset-function works well. But in any case the video doesn’t stop.
This is the stop function:
var video_01 = hypeDocument.getElementById('myvideo_01');
var video_02 = hypeDocument.getElementById('myvideo_02');
if (video_01.currentTime > 0) {
video_01.pause();
}
else if (video_02.currentTime > 0) {
video_02.pause();
}
If you click again on the image to go back to the video, the video gets reset with a function (on load scene):
var video_01 = hypeDocument.getElementById('myvideo_01');
var video_02 = hypeDocument.getElementById('myvideo_02');
if (video_01.currentTime > 0) {
video_01.currentTime = 0;
}
else if (video_02.currentTime > 0) {
video_02.currentTime = 0;
}
We tried all combinations and variations, but the video always starts or continues in the background. Does anyone have an idea to solve our problem?
Thank you.