public IProgressScope AddChildScope(string name, double weight) { var childScope = new ChildProgressScope(name, this, weight); _childScopes.Add(childScope); _totalWeight += weight; this.UpdateChildrenProgress(); return(childScope); }
internal void ChildReportProgress(ChildProgressScope child) { if (this.IsDisposing) { return; } this.UpdateChildrenProgress(); if (ProgressScope.ProgressEquals(child.Progress, 1.0)) { child.Dispose(); } }