r113257 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r113256‎ | r113257 | r113258 >
Date:17:36, 7 March 2012
Author:gwicke
Status:deferred
Tags:
Comment:
Set allTokensProcessed flag for async callbacks from the template expander.
Modified paths:
  • /trunk/extensions/VisualEditor/modules/parser/ext.core.TemplateHandler.js (modified) (history)

Diff [purge]

Index: trunk/extensions/VisualEditor/modules/parser/ext.core.TemplateHandler.js
@@ -179,7 +179,7 @@
180180 if ( tplExpandData.overallAsync ) {
181181 this.manager.env.dp( 'TemplateHandler._expandTemplate: calling back ',
182182 'after parser func ', prefix, ' with res:', res );
183 - return tplExpandData.cb( res, false );
 183+ return tplExpandData.cb( res, false, true );
184184 } else {
185185 this.manager.env.dp( 'TemplateHandler._expandTemplate: sync return ',
186186 'after parser func ', prefix, ' with res:', res );
@@ -202,7 +202,7 @@
203203 new EndTagTk( 'a' )
204204 ];
205205 if ( tplExpandData.overallAsync ) {
206 - return tplExpandData.cb( res, false );
 206+ return tplExpandData.cb( res, false, true );
207207 } else {
208208 return { tokens: res };
209209 }
@@ -295,7 +295,7 @@
296296
297297 if ( tplExpandData.overallAsync ) {
298298 this.manager.env.dp( 'TemplateHandler._onEnd: calling back with res:', res );
299 - tplExpandData.cb( res, false );
 299+ tplExpandData.cb( res, false, true );
300300 } else {
301301 this.manager.env.dp( 'TemplateHandler._onEnd: synchronous return!' );
302302 tplExpandData.result = { tokens: res };

Status & tagging log