Use bad_files to display progress if that is larger
This commit is contained in:
parent
37a3b4678d
commit
5a36a002bf
2 changed files with 4 additions and 3 deletions
|
@ -396,7 +396,7 @@ class Wrapper
|
|||
|
||||
updateProgress: (site_info) ->
|
||||
if site_info.tasks > 0 and site_info.started_task_num > 0
|
||||
@loading.setProgress 1-(site_info.tasks / site_info.started_task_num)
|
||||
@loading.setProgress 1-(Math.max(site_info.tasks, site_info.bad_files) / site_info.started_task_num)
|
||||
else
|
||||
@loading.hideProgress()
|
||||
|
||||
|
|
|
@ -521,6 +521,7 @@ jQuery.extend( jQuery.easing,
|
|||
}).call(this);
|
||||
|
||||
|
||||
|
||||
/* ---- src/Ui/media/Loading.coffee ---- */
|
||||
|
||||
|
||||
|
@ -1299,7 +1300,7 @@ jQuery.extend( jQuery.easing,
|
|||
|
||||
Wrapper.prototype.updateProgress = function(site_info) {
|
||||
if (site_info.tasks > 0 && site_info.started_task_num > 0) {
|
||||
return this.loading.setProgress(1 - (site_info.tasks / site_info.started_task_num));
|
||||
return this.loading.setProgress(1 - (Math.max(site_info.tasks, site_info.bad_files) / site_info.started_task_num));
|
||||
} else {
|
||||
return this.loading.hideProgress();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue