| 126 | // |
| 127 | var timeout = that.processTimeout; |
| 128 | function complete() { |
| 129 | return work(ControlProcessor.processAll). |
| 130 | then(function () { return cancelBlocker(dataContext); }). |
| 131 | then(function Template_renderImpl_Binding_processAll(data) { |
| 132 | return work(_Declarative.processAll, data, !extractedChild && !initial, that.bindingCache); |
| 133 | }). |
| 134 | then(null, function (e) { |
| 135 | if (typeof e === "object" && e.name === "Canceled") { |
| 136 | (extractedChild || d).dispose(); |
| 137 | } |
| 138 | return Promise.wrapError(e); |
| 139 | }); |
| 140 | } |
| 141 | if (timeout) { |
| 142 | if (timeout < 0) { timeout = 0; } |
| 143 | return Promise.timeout(timeout).then(function () { |