W3C home > Mailing lists > Public > public-device-apis-log@w3.org > March 2017

Re: [battery] Detect power saving mode

From: Peter Beverloo via GitHub <sysbot+gh@w3.org>
Date: Wed, 15 Mar 2017 22:16:01 +0000
To: public-device-apis-log@w3.org
Message-ID: <issue_comment.created-286896948-1489616159-sysbot+gh@w3.org>
I think @jimmywarting's suggestion makes sense— if the user explicitly requested apps on their device to save battery it'd be cool for Web apps to be able to help them do that. (The operating system and user agent already do this by e.g. batching or delaying push message delivery.)

I don't see any particular reason to limit the Budget API to background operations, modulo narrowing the scope to get the spec started. I do wonder about it's applicability in this case: the user agent can decide on the cost of an _operation_ such as delivering a push message or giving Background Sync another try, because it's aware of its scope. The request in this issue is different in that it involves action by the developer: decreased WebGL quality, postponing arbitrary JavaScript work, and so on. It'll be difficult to fit the two in the same framework.

Instead, a very simple event (`batterypreservingchange`) +boolean (`battery.preservingBattery`) pair may be sufficient?

GitHub Notification of comment by beverloo
Please view or discuss this issue at https://github.com/w3c/battery/issues/9#issuecomment-286896948 using your GitHub account
Received on Wednesday, 15 March 2017 22:16:07 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 12:18:52 UTC