function waitForNaClModule(embed, moduleDidLoad, responseCallback) {
  if (isLoaded(embed)) {
    moduleDidLoad(true, responseCallback);
    return;
  }
  retries -= 1;
  if (retries <= 0) {
    moduleDidLoad(false, responseCallback);
    return;
  }
  // At this point, there is no discernible load error, and the module
  // has not yet loaded.  Continue to wait.
  responseCallback({type: 'log', message: 'Waiting...'});
  var callback = function() {
    waitForNaClModule(embed, moduleDidLoad, responseCallback);
  };
  setTimeout(callback, retryWait);
}
/**
 * See if a NaCl module is loaded, and if not start a timer that polls
 * the EMBED element associated with the module.  Fail after |retries|
 * attempts.
 * @param {!Element} embed The EMBED element to test.
 * @param {!function} moduleDidLoad This callback is called when the
 *      NaCl module isloaded, or after the number of retires is exceeded.
 *      The callback is passed a bool argument indicating load success.
 */
See if a NaCl module is loaded, and if not start a timer that polls
the EMBED element associated with the module.  Fail after |retries|
attempts.
@param {!Element} embed The EMBED element to test.
@param {!function} moduleDidLoad This callback is called when the
NaCl module isloaded, or after the number of retires is exceeded.
The callback is passed a bool argument indicating load success.
See if a NaCl module is loaded and if not start a timer that polls the EMBED element associated with the module . Fail after |retries| attempts . @param { !Element } embed The EMBED element to test . @param { !function } moduleDidLoad This callback is called when the NaCl module isloaded or after the number of retires is exceeded . The callback is passed a bool argument indicating load success .
function waitForNaClModule(embed, moduleDidLoad, responseCallback) {
  if (isLoaded(embed)) {
    moduleDidLoad(true, responseCallback);
    return;
  }
  retries -= 1;
  if (retries <= 0) {
    moduleDidLoad(false, responseCallback);
    return;
  }
  responseCallback({type: 'log', message: 'Waiting...'});
  var callback = function() {
    waitForNaClModule(embed, moduleDidLoad, responseCallback);
  };
  setTimeout(callback, retryWait);
}
function waitForNaClModule ( embed , moduleDidLoad , responseCallback ) { if ( isLoaded ( embed ) ) { moduleDidLoad ( true , responseCallback ) ; return ; } retries -= 1 ; if ( retries <= 0 ) { moduleDidLoad ( false , responseCallback ) ; return ; } responseCallback ( { type : 'log' , message : 'Waiting...' } ) ; var callback = function ( ) { waitForNaClModule ( embed , moduleDidLoad , responseCallback ) ; } ; setTimeout ( callback , retryWait ) ; }
See if a NaCl module is loaded, and if not start a timer that polls
 the EMBED element associated with the module.
See if a NaCl module is loaded and if not start a timer that polls the EMBED element associated with the module .
// At this point, there is no discernible load error, and the module // has not yet loaded.  Continue to wait.