Found a probably good implementation for the Operation class

git-svn-id: file:///srv/devel/repo-conversion/nusu@33 d2e56fa2-650e-0410-a79f-9358c0239efd
This commit is contained in:
Markus Ewald 2007-07-04 19:19:48 +00:00
parent b73d7846d8
commit 46c0ac68af
3 changed files with 106 additions and 9 deletions

View file

@ -69,7 +69,6 @@ namespace Nuclex.Support.Tracking {
: this() {
// Construct an ObservedProgression around each of the WeightedProgressions
float totalWeight = 0.0f;
foreach(WeightedProgression<ProgressionType> progression in childs) {
this.childs.Add(
new ObservedProgression<ProgressionType>(
@ -80,12 +79,9 @@ namespace Nuclex.Support.Tracking {
);
// Sum up the total weight
totalWeight += progression.Weight;
this.totalWeight += progression.Weight;
}
// Take over the summed weight of all progressions we were given
this.totalWeight = totalWeight;
}
/// <summary>Immediately releases all resources owned by the object</summary>
@ -150,7 +146,7 @@ namespace Nuclex.Support.Tracking {
}
/// <summary>
/// Called when an observed progressions ends
/// Called when an observed progression ends
/// </summary>
private void asyncEnded() {