Skip to content

Commit

Permalink
editorial: Modernize and replace prose with algorithms in BatteryManager
Browse files Browse the repository at this point in the history
Similarly to #45, make the `BatteryManager` section more conformant to
modern spec writing practices, while avoiding making user-visible changes as
much as possible:
- Define a task source for this spec, and switch from "queue a task" to the
  more specific and recent "queue a global task" algorithm.
- Replace a lot of prose with internal slots and algorithms.
- Make the interface attributes simply return the values of the internal
  slots rather than defining logic in their getters.
- Define an actual algorithm for updating internal slots and dispatching
  events. The existing prose just said "the UA must change the attribute and
  fire an event" without really defining how to reach a `BatteryManager`
  object in the first place.
  • Loading branch information
rakuco committed Sep 1, 2021
1 parent eb5b629 commit 7cbd8d2
Showing 1 changed file with 239 additions and 145 deletions.
Loading

0 comments on commit 7cbd8d2

Please sign in to comment.