[Downloads v2] Remove direct updates to `DownloadUIStore` from download control actions
Categories
(Firefox for Android :: Downloads, task)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox143 | --- | fixed |
People
(Reporter: npoon, Assigned: npoon)
References
Details
(Whiteboard: [fxdroid][group4])
Attachments
(3 files)
Currently, when the user pauses / resumes / restarts / deletes / retries a download, the DownloadUIStore updates it's items property, while also sending a broadcast to the AbstractFetchDownloadService, which notifies the BrowserStore of the change. The DownloadUIState is the state that directly determines what is shown in the UI. The expected behaviour is that the browser store gets updated, and since the DownloadUIStore observes the browser store, it knows to update the UI based on the "backend" state. Thus, we should remove our updates to the DownloadUIStore.
A side effect of this bug is Bug 1977393. When Fenix is killed, the DownloadUIStore is disconnected from the AbstractFetchDownloadService and while the play / pause / resume / retry buttons have their state updated, this actually doesn't reflect the current state, which causes the user perception of unresponsiveness.
Ideally, we should find a way to reconnect the service when Fenix is opened again but this is a deep rooted problem in the AbstractFetchDownloadService so we will investigate how to reconnect the service in Bug 1977835. Temporarily, our solution is to just cancel all of the downloads when Fenix is killed
Updated•1 year ago
|
| Assignee | ||
Updated•1 year ago
|
| Assignee | ||
Comment 1•1 year ago
|
||
| Assignee | ||
Comment 2•1 year ago
|
||
| Assignee | ||
Comment 3•1 year ago
|
||
https://hg.mozilla.org/mozilla-central/rev/87d17f1f1c66
https://hg.mozilla.org/mozilla-central/rev/e7cc758d8207
https://hg.mozilla.org/mozilla-central/rev/84fa57ee33db
Description
•