B2G/gecko/browser/devtools/shared/SplitView.jsm
/**
   * Append an item to the split view.
   *
   * @param DOMElement aSummary
   *        The summary element for the item.
   * @param DOMElement aDetails
   *        The details element for the item.
   * @param object aOptions
   *     Optional object that defines custom behavior and data for the item.
   *     All properties are optional :
   *     - function(DOMElement summary, DOMElement details, object data) onCreate
   *         Called when the item has been added.
   *     - function(summary, details, data) onShow
   *         Called when the item is shown/active.
   *     - function(summary, details, data) onHide
   *         Called when the item is hidden/inactive.
   *     - function(summary, details, data) onDestroy
   *         Called when the item has been removed.
   *     - object data
   *         Object to pass to the callbacks above.
   *     - number ordinal
   *         Items with a lower ordinal are displayed before those with a
   *         higher ordinal.
   */
Append an item to the split view.
@param DOMElement aSummary
The summary element for the item.
@param DOMElement aDetails
The details element for the item.
@param object aOptions
Optional object that defines custom behavior and data for the item.
All properties are optional :
- function(DOMElement summary, DOMElement details, object data) onCreate
Called when the item has been added.
- function(summary, details, data) onShow
Called when the item is shown/active.
- function(summary, details, data) onHide
Called when the item is hidden/inactive.
- function(summary, details, data) onDestroy
Called when the item has been removed.
- object data
Object to pass to the callbacks above.
- number ordinal
Items with a lower ordinal are displayed before those with a
higher ordinal.
Append an item to the split view . @param DOMElement aSummary The summary element for the item . @param DOMElement aDetails The details element for the item . @param object aOptions Optional object that defines custom behavior and data for the item . All properties are optional : - function ( DOMElement summary DOMElement details object data ) onCreate Called when the item has been added . - function ( summary details data ) onShow Called when the item is shown / active . - function ( summary details data ) onHide Called when the item is hidden / inactive . - function ( summary details data ) onDestroy Called when the item has been removed . - object data Object to pass to the callbacks above . - number ordinal Items with a lower ordinal are displayed before those with a higher ordinal .
function ASV_appendItem(aSummary, aDetails, aOptions)
  {
    let binding = aOptions || {};
    binding._summary = aSummary;
    binding._details = aDetails;
    aSummary.setUserData(BINDING_USERDATA, binding, null);
    this._nav.appendChild(aSummary);
    aSummary.addEventListener("click", function onSummaryClick(aEvent) {
      aEvent.stopPropagation();
      this.activeSummary = aSummary;
    }.bind(this), false);
    this._side.appendChild(aDetails);
    if (binding.onCreate) {
      this._root.ownerDocument.defaultView.setTimeout(function () {
        binding.onCreate(aSummary, aDetails, binding.data);
      }, 0);
    }
  }
function ASV_appendItem ( aSummary , aDetails , aOptions ) { let binding = aOptions || { } ; binding . _summary = aSummary ; binding . _details = aDetails ; aSummary . setUserData ( BINDING_USERDATA , binding , null ) ; this . _nav . appendChild ( aSummary ) ; aSummary . addEventListener ( "click" , function onSummaryClick ( aEvent ) { aEvent . stopPropagation ( ) ; this . activeSummary = aSummary ; } . bind ( this ) , false ) ; this . _side . appendChild ( aDetails ) ; if ( binding . onCreate ) { this . _root . ownerDocument . defaultView . setTimeout ( function ( ) { binding . onCreate ( aSummary , aDetails , binding . data ) ; } , 0 ) ; } }
Append an item to the split view.
Append an item to the split view .
// queue onCreate handler