dont use document.fullscreen, fixes #18

This commit is contained in:
Sanjay B 2021-10-24 17:50:17 +05:30
parent 09d3dcc43d
commit 34c1a993f2

View file

@ -41,7 +41,7 @@ document.querySelector('a#play-fullscreen').addEventListener('click', event => {
} }
video.addEventListener('play', enterFullscreen); video.addEventListener('play', enterFullscreen);
video.addEventListener('fullscreenchange', event => { video.addEventListener('fullscreenchange', event => {
if (!document.fullscreen) { if (document.fullscreenElement === null) {
continueTimecode = video.currentTime continueTimecode = video.currentTime
video.remove() video.remove()
if (document.fullscreenElement) { if (document.fullscreenElement) {