B2G/gecko/browser/components/downloads/content/indicator.js
/**
   * Ensures that the user interface elements required to display the indicator
   * are loaded, then invokes the given callback.
   */
Ensures that the user interface elements required to display the indicator
are loaded, then invokes the given callback.
Ensures that the user interface elements required to display the indicator are loaded then invokes the given callback .
function DIV_ensureOperational(aCallback)
  {
    if (this._operational) {
      aCallback();
      return;
    }
    function DIV_EO_callback() {
      this._operational = true;
      if (this._initialized) {
        DownloadsCommon.indicatorData.refreshView(this);
      }
      aCallback();
    }
    DownloadsOverlayLoader.ensureOverlayLoaded(
                                 DownloadsButton.kIndicatorOverlay,
                                 DIV_EO_callback.bind(this));
  }
function DIV_ensureOperational ( aCallback ) { if ( this . _operational ) { aCallback ( ) ; return ; } function DIV_EO_callback ( ) { this . _operational = true ; if ( this . _initialized ) { DownloadsCommon . indicatorData . refreshView ( this ) ; } aCallback ( ) ; } DownloadsOverlayLoader . ensureOverlayLoaded ( DownloadsButton . kIndicatorOverlay , DIV_EO_callback . bind ( this ) ) ; }
Ensures that the user interface elements required to display the indicator
 are loaded, then invokes the given callback.
Ensures that the user interface elements required to display the indicator are loaded then invokes the given callback .
// If the view is initialized, we need to update the elements now that // they are finally available in the document.