Closed
Bug 899122
Opened 11 years ago
Closed 11 years ago
Include previously downloaded data in progress reports when restarting
Categories
(Toolkit :: Downloads API, defect)
Toolkit
Downloads API
Tracking
()
RESOLVED
FIXED
mozilla25
People
(Reporter: Paolo, Assigned: Paolo)
References
Details
Attachments
(1 file)
(deleted),
patch
|
enndeakin
:
review+
|
Details | Diff | Splinter Review |
When a download is restarted from where it stopped, progress reports should
include the bytes that were already downloaded. This provides a more intuitive
behavior to the progress bar in the user interface.
Assignee | ||
Comment 1•11 years ago
|
||
The setSha256Hash fix is unrelated, but it fixed an issue I encountered while
testing this patch in the user interface.
Assignee: nobody → paolo.mozmail
Status: NEW → ASSIGNED
Attachment #783719 -
Flags: review?(enndeakin)
Comment 2•11 years ago
|
||
Comment on attachment 783719 [details] [diff] [review]
The patch
>+ // Continue when the number of bytes we received is correct, then check that
>+ // progress is at about 75 percent (while the exact figure may vary).
>+ yield deferMidway.promise;
>+ do_check_true(download.progress > 72 && download.progress < 78);
Why isn't this exactly 75%?
Assignee | ||
Comment 3•11 years ago
|
||
(In reply to Neil Deakin from comment #2)
> Why isn't this exactly 75%?
We have rounding issues because the total number of bytes in the request isn't a
multiple of four. I can clarify the comment.
Assignee | ||
Comment 4•11 years ago
|
||
Updated to:
// Continue when the number of bytes we received is correct, then check that
// progress is at about 75 percent. The exact figure may vary because of
// rounding issues, since the total number of bytes in the response might not
// be a multiple of four.
Updated•11 years ago
|
Attachment #783719 -
Flags: review?(enndeakin) → review+
Assignee | ||
Comment 5•11 years ago
|
||
Comment 6•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
You need to log in
before you can comment on or make changes to this bug.
Description
•