internal void Process(ProgressScope progress) { foreach (var taskInfo in _tasks) { var childProgress = progress.AddChildScope(taskInfo.Task.Name, taskInfo.Weight); App.BeginInvokeBackground(() => taskInfo.Task.PreProcess(childProgress)); _taskNodes[taskInfo.Task].Process((ProgressScope)childProgress); App.BeginInvokeBackground(() => taskInfo.Task.PostProcess(childProgress)); App.BeginInvokeBackground(childProgress.Dispose); } }
internal void ChildReportProgress(ChildProgressScope child) { if (this.IsDisposing) { return; } this.UpdateChildrenProgress(); if (ProgressScope.ProgressEquals(child.Progress, 1.0)) { child.Dispose(); } }