How to allow system sleep on non-full screen html5 video?

We have created a small chat client in our office that runs in a browser. It processes people posting pictures and gifs and embeds them. We recently added support for imgur and gfycat html 5 videos (it will automatically convert gifs to mp4 / webm). An easy side effect of this is now anyone using chrome or firefox will find that their monitor will never turn off.

You can see in powercfg the culprit for these videos:

C:\WINDOWS\system32>powercfg /requests
DISPLAY:
[PROCESS] \Device\HarddiskVolume2\Program Files (x86)\Google\Chrome\Application\chrome.exe
Playing video
[PROCESS] \Device\HarddiskVolume2\Program Files (x86)\Mozilla Firefox\firefox.exe

      

If you pause the video, the recordings in powercfg will disappear. Switching to another tab, minimizing chrome, even locking the screen prevents the system from turning off the monitor. Internet Explorer seems to be the only browser that behaves as you'd expect and only prevents sleep when the video is full screen.

Is there a way to mark a video tag as "irrelevant" and basically tell the browser that it's okay to let the computer go to sleep while playing that video?

+3


source to share


1 answer


There seems to be a bug in Google Chrome 38 (current version at the time of this writing) that causes the screen saver to suppress when playing HTML5 videos. Generally, screensaver suppression should only be performed if the video is playing in full screen mode.



This issue seems to have been fixed in Google Chrome 39 Beta, as it looks like a temporary fix .

0


source







All Articles