Allow in-progress downloads to show up before DownloadManagerImpl fully initializes
With the introduction of SimpleDownloadManagerCoordinator, it has 2 stages. In the first stage, OnDownloadsInitialized() will be called for in-progress downloads. In this stage, clients should be able to access all the in-progress downloads. In the 2nd stage, OnDownloadsInitialized() is called for all downloads. However, if InProgressDownloadManager is passed to a DownloadManagerImpl, the DownloadManagerImpl will not return the in-progress downloads on GetAllDownloads() unless it is fully initialized. As a result, this causes a wierd issue that after stage 1, calling GetAllDownloads() sometimes may not return all the downloads until stage 2 completes. BUG=942770 Change-Id: I44e589ee1bd174c5fef86ec9c8170ac94e6e1b5c Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1603208Reviewed-by:David Trainor <dtrainor@chromium.org> Commit-Queue: Min Qin <qinmin@chromium.org> Cr-Commit-Position: refs/heads/master@{#658795}
Showing
Please register or sign in to comment