B2G/gecko/browser/devtools/webconsole/webconsole.js
/**
   * The click event handler for evaluation results in the output.
   *
   * @private
   * @param object aResponse
   *        The JavaScript evaluation response received from the server.
   * @param nsIDOMNode aLink
   *        The message node for which we are handling events.
   */
The click event handler for evaluation results in the output.
@private
@param object aResponse
The JavaScript evaluation response received from the server.
@param nsIDOMNode aLink
The message node for which we are handling events.
The click event handler for evaluation results in the output . @private @param object aResponse The JavaScript evaluation response received from the server . @param nsIDOMNode aLink The message node for which we are handling events .
function JST__evalOutputClick(aResponse, aLinkNode)
  {
    if (aLinkNode._panelOpen) {
      return;
    }
    let options = {
      title: aResponse.input,
      anchor: aLinkNode,
      data: {
        objectPropertiesProvider: this.hud.objectPropertiesProvider.bind(this.hud),
        releaseObject: this.hud._releaseObject.bind(this.hud),
      },
    };
    let propPanel;
    options.updateButtonCallback = function JST__evalUpdateButton() {
      let onResult =
        this._evalOutputUpdatePanelCallback.bind(this, options, propPanel,
                                                 aResponse);
      this.webConsoleClient.evaluateJS(aResponse.input, onResult);
    }.bind(this);
    let onPopupHide = function JST__evalInspectPopupHide() {
      propPanel.panel.removeEventListener("popuphiding", onPopupHide, false);
      if (!aLinkNode.parentNode && aLinkNode._objectActors) {
        aLinkNode._objectActors.forEach(this.hud._releaseObject, this.hud);
        aLinkNode._objectActors = null;
      }
    }.bind(this);
    this.hud.objectPropertiesProvider(aResponse.result.actor,
      function _onObjectProperties(aProperties) {
        options.data.objectProperties = aProperties;
        propPanel = this.openPropertyPanel(options);
        propPanel.panel.setAttribute("hudId", this.hudId);
        propPanel.panel.addEventListener("popuphiding", onPopupHide, false);
      }.bind(this));
  }
function JST__evalOutputClick ( aResponse , aLinkNode ) { if ( aLinkNode . _panelOpen ) { return ; } let options = { title : aResponse . input , anchor : aLinkNode , data : { objectPropertiesProvider : this . hud . objectPropertiesProvider . bind ( this . hud ) , releaseObject : this . hud . _releaseObject . bind ( this . hud ) , } , } ; let propPanel ; options . updateButtonCallback = function JST__evalUpdateButton ( ) { let onResult = this . _evalOutputUpdatePanelCallback . bind ( this , options , propPanel , aResponse ) ; this . webConsoleClient . evaluateJS ( aResponse . input , onResult ) ; } . bind ( this ) ; let onPopupHide = function JST__evalInspectPopupHide ( ) { propPanel . panel . removeEventListener ( "popuphiding" , onPopupHide , false ) ; if ( ! aLinkNode . parentNode && aLinkNode . _objectActors ) { aLinkNode . _objectActors . forEach ( this . hud . _releaseObject , this . hud ) ; aLinkNode . _objectActors = null ; } } . bind ( this ) ; this . hud . objectPropertiesProvider ( aResponse . result . actor , function _onObjectProperties ( aProperties ) { options . data . objectProperties = aProperties ; propPanel = this . openPropertyPanel ( options ) ; propPanel . panel . setAttribute ( "hudId" , this . hudId ) ; propPanel . panel . addEventListener ( "popuphiding" , onPopupHide , false ) ; } . bind ( this ) ) ; }
The click event handler for evaluation results in the output.
The click event handler for evaluation results in the output .
// Data to inspect.