Open Bug 1525466 Opened 5 years ago Updated 7 months ago

Add GV API for battery settings (power-saving mode)

Categories

(GeckoView :: General, enhancement, P3)

All
Android
enhancement

Tracking

(firefox-esr60 wontfix, firefox65 wontfix, firefox66 wontfix, firefox67 wontfix, firefox68 affected)

Tracking Status
firefox-esr60 --- wontfix
firefox65 --- wontfix
firefox66 --- wontfix
firefox67 --- wontfix
firefox68 --- affected

People

(Reporter: cpeterson, Unassigned)

References

()

Details

(Whiteboard: [geckoview:fenix:p3])

Fenix will have a power-saving mode that users can enable:

https://github.com/mozilla-mobile/fenix/issues/240

Fenix needs a GV API to tell Gecko when to enter power-saving mode. Gecko features that have performance/power tradeoffs can then check this one flag to decide when to prioritize power savings over performance.

[geckoview:fenix:m3] so the GV API is ready when Fenix plans to implement the power-saving setting in Fenix M4.

https://github.com/orgs/mozilla-mobile/projects/5

Note that in those mocks the "battery saver" can be turned on/off on a per-site basis:
https://github.com/mozilla-mobile/fenix/issues/191#issuecomment-460509170

(In reply to Sebastian Kaspari (:sebastian; :pocmo) from comment #1)

Note that in those mocks the "battery saver" can be turned on/off on a per-site basis:
https://github.com/mozilla-mobile/fenix/issues/191#issuecomment-460509170

That would certainly complicate Gecko's implementation. If we treat "battery saver" like a site permission, then core Gecko would need to be able to query the app for the current site's "battery saver" mode. For example, Gecko's video decoder might need to know which site a video is associated with and then be able to call out through a GV API to the app if we wanted to implement connect the battery saver to Media Capabilities's smooth and powerEfficient flags, as Nils suggested here:

https://github.com/mozilla-mobile/fenix/issues/254#issuecomment-460830253

Barbara, is configuring battery saver settings for individual sites on the Fenix roadmap? Bram's UX mockup showed per-site battery saving settings, but I don't know if that is an intended feature requirement or just a random example for the site permissions UI.

https://github.com/mozilla-mobile/fenix/issues/191#issuecomment-460509170

Per-site battery saving settings would be complicated for Gecko to support and would reduce the total battery saving benefits.

Flags: needinfo?(bbermes)

Fenix plans to implement power-saving features in M4, so GV should provide the API in M3.

https://github.com/mozilla-mobile/fenix/issues/240

Summary: Add GV API to toggle power-saving mode → Add GV API for battery settings (power-saving mode)
Whiteboard: [geckoview:fenix:p1] [geckoview:fenix:m3] → [geckoview:fenix:m3]

I'm pushing this bug from Fenix M3 to M4 until we have more details from the Fenix team as to what they want Gecko battery saving mode to actually do.

Whiteboard: [geckoview:fenix:m3] → [geckoview:fenix:m4]

Fenix's Battery Saver feature has been deferred to post-MVP: https://github.com/mozilla-mobile/fenix/issues/240

Flags: needinfo?(bbermes)
Whiteboard: [geckoview:fenix:m4] → [geckoview:fenix:p3]

I'm editing a bunch of GeckoView bugs. If you'd like to filter all this bugmail, search and destroy emails containing this UUID:

e88a5094-0fc0-4b7c-b7c5-aef00a11dbc9

Priority: P1 → P3
See Also: → 1588539
Severity: normal → S3

Tasks and enhancements should have severity N/A.

Severity: S3 → N/A
You need to log in before you can comment on or make changes to this bug.