dwf/rva: actionColllection now has an optional finishCallback

This commit is contained in:
pivotal
2008-12-04 09:37:36 -08:00
parent f5486bde35
commit 735ebd6c66
3 changed files with 95 additions and 59 deletions

View File

@@ -64,6 +64,13 @@ var actionCollection = function () {
finished: false,
results: nestedResults(),
finish: function () {
if (that.finishCallback) {
that.finishCallback();
}
that.finished = true;
},
report: function (result) {
that.results.push(result);
},
@@ -80,7 +87,7 @@ var actionCollection = function () {
next: function() {
if (that.index >= that.actions.length) {
that.finished = true;
that.finish();
return;
}