Fixed download bugs

This commit is contained in:
Geomitron
2020-05-10 13:53:54 -04:00
parent 1cfb5f4e93
commit a81fddea3b
5 changed files with 10 additions and 8 deletions

View File

@@ -29,9 +29,11 @@ export class StatusBarComponent {
ref: ChangeDetectorRef
) {
downloadService.onDownloadUpdated(() => {
this.downloading = downloadService.downloadCount > 0
this.percent = downloadService.totalPercent
ref.detectChanges()
setTimeout(() => { // Make sure this is the last callback executed to get the accurate downloadCount
this.downloading = downloadService.downloadCount > 0
this.percent = downloadService.totalPercent
ref.detectChanges()
}, 0)
})
searchService.onSearchChanged(() => {