function changeVideoSource(blob, videoElement, videoBox) { videoBox = videoBox || ""; var blobUrl = URL.createObjectURL(blob); videoElement.src = blobUrl; $(videoElement).show(); if (!isnavigated) { isnavigated = true; if (getint(_psec[_pseq - 1]) > 0) { videoElement.currentTime = getint(_psec[_pseq - 1]); } else { //videoElement.play(); } } else { //videoElement.play(); } if (videoBox != "") { videoBox.show(); } $("#loading").hide(); if ($("#prenextbox").length > 0) { $("#prenextbox").show(); } } function fetchVideo(url) { return fetch(url).then(function (response) { return response.blob(); }); }