4 ms·
Permissions probably aren't that great UX-wise, but couldn't the API have been simplified instead, only allowing web sites to query remaining battery time? To m
by currysausage 10y ago
Permissions probably aren't that great UX-wise, but couldn't the API have been simplified instead, only allowing web sites to query remaining battery time? To me, it sounds like the API is vastly overengineered.
- dalai 10y agoExactly what I thought. The website needs to know whether the battery is low or not, not even how much time it still has. Let the API return a true/false to that question and, if necessary for some usecases, hide the rest behind a default deny permission.
- teh 10y agoThat still leaks a number, let's say it's 0-5h and resolution is 1 minute, that's 60*5 == 300, so roughly 8 bits of entropy. A `onBatteryLow` callback might do the trick?