B2G/gecko/browser/devtools/debugger/debugger-view.js
/**
   * Adds a frame to the stackframes container.
   * If the frame already exists (was previously added), null is returned.
   * Otherwise, the newly created element is returned.
   *
   * @param number aDepth
   *        The frame depth specified by the debugger.
   * @param string aFrameNameText
   *        The name to be displayed in the list.
   * @param string aFrameDetailsText
   *        The details to be displayed in the list.
   * @return object
   *         The newly created html node representing the added frame.
   */
Adds a frame to the stackframes container.
If the frame already exists (was previously added), null is returned.
Otherwise, the newly created element is returned.

@param number aDepth
The frame depth specified by the debugger.
@param string aFrameNameText
The name to be displayed in the list.
@param string aFrameDetailsText
The details to be displayed in the list.
@return object
The newly created html node representing the added frame.
Adds a frame to the stackframes container . If the frame already exists ( was previously added ) null is returned . Otherwise the newly created element is returned . @param number aDepth The frame depth specified by the debugger . @param string aFrameNameText The name to be displayed in the list . @param string aFrameDetailsText The details to be displayed in the list . @return object The newly created html node representing the added frame .
function DVF_addFrame(aDepth, aFrameNameText, aFrameDetailsText) {
    if (document.getElementById("stackframe-" + aDepth)) {
      return null;
    }
    DebuggerView.showPanesIfAllowed();
    let frame = document.createElement("box");
    let frameName = document.createElement("label");
    let frameDetails = document.createElement("label");
    frame.id = "stackframe-" + aDepth;
    frame.className = "dbg-stackframe list-item";
    frameName.className = "dbg-stackframe-name plain";
    frameDetails.className = "dbg-stackframe-details plain";
    frameName.setAttribute("value", aFrameNameText);
    frameDetails.setAttribute("value", aFrameDetailsText);
    let spacer = document.createElement("spacer");
    spacer.setAttribute("flex", "1");
    frame.appendChild(frameName);
    frame.appendChild(spacer);
    frame.appendChild(frameDetails);
    this._frames.appendChild(frame);
    return frame;
  }
function DVF_addFrame ( aDepth , aFrameNameText , aFrameDetailsText ) { if ( document . getElementById ( "stackframe-" + aDepth ) ) { return null ; } DebuggerView . showPanesIfAllowed ( ) ; let frame = document . createElement ( "box" ) ; let frameName = document . createElement ( "label" ) ; let frameDetails = document . createElement ( "label" ) ; frame . id = "stackframe-" + aDepth ; frame . className = "dbg-stackframe list-item" ; frameName . className = "dbg-stackframe-name plain" ; frameDetails . className = "dbg-stackframe-details plain" ; frameName . setAttribute ( "value" , aFrameNameText ) ; frameDetails . setAttribute ( "value" , aFrameDetailsText ) ; let spacer = document . createElement ( "spacer" ) ; spacer . setAttribute ( "flex" , "1" ) ; frame . appendChild ( frameName ) ; frame . appendChild ( spacer ) ; frame . appendChild ( frameDetails ) ; this . _frames . appendChild ( frame ) ; return frame ; }
Adds a frame to the stackframes container.
Adds a frame to the stackframes container .
// Make sure we don't duplicate anything. // Stackframes are UI elements which benefit from visible panes. // Create a list item to be added to the stackframes container. // This list should display the name and details for the frame. // Return the element for later use if necessary.