bin/XULRunner21_0/components/nsUpdateService.js
/**
   * Called when a connection should be resumed
   */
Called when a connection should be resumed
Called when a connection should be resumed
function AUS_attemptResume() {
    LOG("UpdateService:_attemptResume")
    if (this._downloader && this._downloader._patch &&
        this._downloader._patch.state == STATE_DOWNLOADING &&
        this._downloader._update) {
      LOG("UpdateService:_attemptResume - _patch.state: " +
          this._downloader._patch.state);
      writeStatusFile(getUpdatesDir(), STATE_DOWNLOADING);
      var status = this.downloadUpdate(this._downloader._update,
                                       this._downloader.background);
      LOG("UpdateService:_attemptResume - downloadUpdate status: " + status);
      if (status == STATE_NONE) {
        cleanupActiveUpdate();
      }
      return;
    }
    this.backgroundChecker.checkForUpdates(this, false);
  }
function AUS_attemptResume ( ) { LOG ( "UpdateService:_attemptResume" ) if ( this . _downloader && this . _downloader . _patch && this . _downloader . _patch . state == STATE_DOWNLOADING && this . _downloader . _update ) { LOG ( "UpdateService:_attemptResume - _patch.state: " + this . _downloader . _patch . state ) ; writeStatusFile ( getUpdatesDir ( ) , STATE_DOWNLOADING ) ; var status = this . downloadUpdate ( this . _downloader . _update , this . _downloader . background ) ; LOG ( "UpdateService:_attemptResume - downloadUpdate status: " + status ) ; if ( status == STATE_NONE ) { cleanupActiveUpdate ( ) ; } return ; } this . backgroundChecker . checkForUpdates ( this , false ) ; }
Called when a connection should be resumed
Called when a connection should be resumed
// If a download is in progress, then resume it. // Make sure downloading is the state for selectPatch to work correctly