Closed
Bug 1369194
Opened 7 years ago
Closed 7 years ago
Remove navigator.requestWakeLock()
Categories
(Core :: DOM: Core & HTML, enhancement, P3)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla59
Tracking | Status | |
---|---|---|
firefox59 | --- | fixed |
People
(Reporter: gsvelto, Assigned: agashlin)
References
(Blocks 2 open bugs)
Details
Attachments
(2 files)
(deleted),
patch
|
gsvelto
:
review+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
baku
:
review+
|
Details | Diff | Splinter Review |
+++ This bug was initially created as a clone of Bug #1306391 +++
navigator.requestWakeLock() was introduced in B2G to allow system code to grab various Android wakelocks. Since it's not used anymore it should be removed together with related code in the wakelocks implementation.
Updated•7 years ago
|
Blocks: nukeb2g
No longer depends on: nukeb2g, 1306604, 1306605, 1306648, 1306801, 1307238, 1309632, 1312807, 1316153, 1317711, 1320404, 1325478, 1331694, 1336917, 1340952, 1347045, 1351089, 1357322, 1357368, 1358005, 1365843, 1367514, 1368549, 970125, 989373, 1278716, 1284674, 1290668, 1291291, 1299390, 1299500, 1306137, 1306397, 1306555, 1306556, 1306603, 1306641, 1306772, 1306778, 1306779, 1306782, 1307332, 1307456, 1307467, 1307491, 1307525, 1308073, 1308075, 1308202, 1308267, 1308319, 1308363, 1308943, 1308955, 1309028, 1309030, 1309031, 1309593, 1309719, 1309723, 1310020, 1310027, 1310094, 1310097, 1310101, 1310297, 1310366, 1310378, 1310436, 1310721, 1310845, 1310859, 1310863, 1310864, 1310905, 1310910, 1311057, 1311149, 1311206, 1311214, 1311246, 1311885, 1312101, 1312164, 1312591, 1312800, 1313045, 1313062, 1313155, 1313159, 1313167, 1313169, 1313221, 1313281, 1313549, 1313788, 1313789, 1315302, 1315798, 1316408, 1316718, 1317656, 1317853, 1317983, 1318206, 1318207, 1318209, 1318210, 1318217, 1318218, 1318342, 1318343, 1318344, 1318354, 1318356, 1318562, 1318874, 1318875, 1318879, 1318881, 1318883, 1318887, 1318888, 1318904, 1318936, 1326445, 1330772, 1331838, 1333503, 1333892, 1337054, 1339353, 1350497, 1351093, 1355179, 1355752, 1356913, 1357323, 1357326, 1357649, 1357828, 1359988, 1361009, 1363249
Updated•7 years ago
|
Priority: -- → P3
Comment 3•7 years ago
|
||
Is this a proposal to remove the `navigator.requestWakeLock` API that is provided by the pref `dom.wakelock.enabled` in Fx? Because there is another bug open (https://bugzilla.mozilla.org/show_bug.cgi?id=1054113) to enable it for Firefox for Android. I don't know enough about how much code is shared between B2G and Fx.
Updated•7 years ago
|
Keywords: site-compat
Reporter | ||
Comment 4•7 years ago
|
||
(In reply to Barret Rennie [:brennie] from comment #3)
> Is this a proposal to remove the `navigator.requestWakeLock` API that is
> provided by the pref `dom.wakelock.enabled` in Fx? Because there is another
> bug open (https://bugzilla.mozilla.org/show_bug.cgi?id=1054113) to enable it
> for Firefox for Android. I don't know enough about how much code is shared
> between B2G and Fx.
IIRC this API is non-standard so it shouldn't be enabled, I think it's safe if we close that bug as WONTFIX.
Comment 5•7 years ago
|
||
Sorry, I got this mixed up with the `navigator.getWakeLock` API from https://w3c.github.io/wake-lock/. Thanks for clearing things up, cheers!
Updated•7 years ago
|
Assignee | ||
Updated•7 years ago
|
Assignee: nobody → agashlin
Assignee | ||
Comment 6•7 years ago
|
||
This is a straightforward removal of the interface. I don't touch MozWakeLock in this patch because I'm not sure if I can safely remove it without disturbing the other users of WakeLock.
Attachment #8930219 -
Flags: review?(gsvelto)
Reporter | ||
Comment 7•7 years ago
|
||
Comment on attachment 8930219 [details] [diff] [review]
1. remove navigator.requestWaitLock()
LGTM. There seems to be no more to remove since the remaining bits of implementation are still in use in the various widgets (e.g. to keep the screen on if the user is watching a video, etc...).
Attachment #8930219 -
Flags: review?(gsvelto) → review+
Assignee | ||
Comment 8•7 years ago
|
||
The only place where MozWaitLock was used was the return value of navigator.requestWaitLock, so this patch removes it. I also removed WaitLock from the cycle collector since it holds nothing that needs to be collected now that it doesn't need to be wrapped for JS.
I'm unfamiliar with these mechanisms so hopefully I've done it right, wake lock functionality still seems to behave correctly.
Attachment #8930308 -
Flags: review?(gsvelto)
Reporter | ||
Comment 9•7 years ago
|
||
Comment on attachment 8930308 [details] [diff] [review]
2. remove MozWaitLock
Review of attachment 8930308 [details] [diff] [review]:
-----------------------------------------------------------------
I don't feel confident in reviewing changes that touch cycle-collected stuff myself since I've had only little exposure to it. I'm redirecting the review to a DOM peer.
Attachment #8930308 -
Flags: review?(gsvelto) → review?(amarchesini)
Updated•7 years ago
|
Attachment #8930308 -
Flags: review?(amarchesini) → review+
Assignee | ||
Comment 10•7 years ago
|
||
Try looks good to me, requesting checkin.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=580b4a4541a3634831103c92b3cf5461e54a064c
Comment 11•7 years ago
|
||
Pushed by ryanvm@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/951c0a271074
Remove navigator.requestWakeLock(). r=gsvelto, r=baku
https://hg.mozilla.org/integration/mozilla-inbound/rev/7b021ff1814f
Remove MozWakeLock. r=baku
Keywords: checkin-needed
Assignee | ||
Updated•7 years ago
|
Status: NEW → ASSIGNED
Comment 12•7 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/951c0a271074
https://hg.mozilla.org/mozilla-central/rev/7b021ff1814f
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
status-firefox59:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla59
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•