Closed
Bug 1245600
Opened 8 years ago
Closed 8 years ago
Implement chrome.downloads.onChanged
Categories
(WebExtensions :: Untriaged, defect)
WebExtensions
Untriaged
Tracking
(firefox47 fixed)
Tracking | Status | |
---|---|---|
firefox47 | --- | fixed |
People
(Reporter: aswan, Assigned: aswan)
References
(Blocks 1 open bug)
Details
(Whiteboard: [downloads])
Attachments
(1 file)
Part of supporting chrome.downloads in WebExtensions https://developer.chrome.com/extensions/downloads#event-onChanged
Updated•8 years ago
|
Whiteboard: [downloads]
Assignee | ||
Updated•8 years ago
|
Iteration: --- → 47.3 - Mar 7
Assignee | ||
Updated•8 years ago
|
Assignee: nobody → aswan
Assignee | ||
Comment 1•8 years ago
|
||
I played around with this in Chrome a bit and encountered some quirks I want to document. The fields that are documented as being possibly referenced in a change event are: url, filename, danger, mime, startTime, endTime, state, canResume, paused, error, totalBytes, fileSize, exists Of these, I can't see how url, mime, or startTime can ever change once a download begins (and we don't get a change event for a brand new download, onCreated exists for that). I did see a change event for exists going from true->false after I deleted a downloaded file from the downloads directory, but the event came many minutes after the file was deleted (I think it happened at the time I started a new unrelated download) In some simple testing (doing a download and letting it finish, pausing and restarting a download, canceling a download), I never saw change events for totalBytes, fileSize, or a false->true change for exists. I think that by far the biggest benefit will get from this is the in_progress->completed change on the state field, so I'd like to just start with that and defer the rest to a subsequent bug.
Assignee | ||
Comment 2•8 years ago
|
||
Review commit: https://reviewboard.mozilla.org/r/38347/diff/#index_header See other reviews: https://reviewboard.mozilla.org/r/38347/
Attachment #8726982 -
Flags: review?(kmaglione+bmo)
Comment 3•8 years ago
|
||
Comment on attachment 8726982 [details] MozReview Request: Bug 1245600 - Implement chrome.downloads.onChanged for state r?kmag https://reviewboard.mozilla.org/r/38347/#review34891 ::: toolkit/components/extensions/ext-downloads.js:23 (Diff revision 1) > + runSafeSync, Please sort property names. ::: toolkit/components/extensions/ext-downloads.js:138 (Diff revision 1) > + events: new EventEmitter(), We generally use `EventEmitter.decorate` instead.
Attachment #8726982 -
Flags: review?(kmaglione+bmo) → review+
Assignee | ||
Comment 4•8 years ago
|
||
Comment on attachment 8726982 [details] MozReview Request: Bug 1245600 - Implement chrome.downloads.onChanged for state r?kmag Review request updated; see interdiff: https://reviewboard.mozilla.org/r/38347/diff/1-2/
Assignee | ||
Updated•8 years ago
|
Keywords: checkin-needed
Comment 6•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/0c220ff8ce85
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox47:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla47
Updated•6 years ago
|
Product: Toolkit → WebExtensions
You need to log in
before you can comment on or make changes to this bug.
Description
•