Closed Bug 968603 Opened 11 years ago Closed 11 years ago

Add screen WakeLockListener on Windows to disable screensaver

Categories

(Core :: Audio/Video, defect)

x86_64
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla30

People

(Reporter: cpearce, Assigned: cpearce)

References

Details

Attachments

(1 file, 1 obsolete file)

We want the screensaver to disable during <video> playback, and WebRTC calls too. It's pretty simple to achieve this, we need to add a nsIDOMMozWakeLockListener which disables the screen saver on "locked-foreground" state, and re-enables it otherwise. For example, this is done for Metrofox already, using a WinRT API: http://mxr.mozilla.org/mozilla-central/source/widget/windows/winrt/MetroAppShell.cpp#54 This bug covers Windows desktop implementation, we'll need something similar for other platforms. There is discussion in bug 517870 as to what APIs to use on other platforms to implement this.
Attached patch Patch (obsolete) (deleted) — Splinter Review
Add a wake lock listener in Win32's appshell to disable the screen saver when Gecko wants to. So we can disable the screen saver during video playback on Windows.
Attachment #8371200 - Flags: review?(jmathies)
Comment on attachment 8371200 [details] [diff] [review] Patch Review of attachment 8371200 [details] [diff] [review]: ----------------------------------------------------------------- I bet this would work on both platforms.
Attachment #8371200 - Flags: review?(jmathies) → review+
Attached patch Patch ready for landing (deleted) — Splinter Review
Fixed a compile error discovered on Try. Patch ready for landing. Re-trying: https://tbpl.mozilla.org/?tree=Try&rev=eed2741433c6
Attachment #8371765 - Flags: review+
Attachment #8371200 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
Depends on: 963366
Depends on: 1063995
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: