B2G/gecko/browser/devtools/webconsole/webconsole.js
/**
   * Check if the given output node is scrolled to the bottom.
   *
   * @param nsIDOMNode aOutputNode
   * @return boolean
   *         True if the output node is scrolled to the bottom, or false
   *         otherwise.
   */
Check if the given output node is scrolled to the bottom.
@param nsIDOMNode aOutputNode
@return boolean
True if the output node is scrolled to the bottom, or false
otherwise.
Check if the given output node is scrolled to the bottom . @param nsIDOMNode aOutputNode @return boolean True if the output node is scrolled to the bottom or false otherwise .
function Utils_isOutputScrolledToBottom(aOutputNode)
  {
    let lastNodeHeight = aOutputNode.lastChild ?
                         aOutputNode.lastChild.clientHeight : 0;
    let scrollBox = aOutputNode.scrollBoxObject.element;
    return scrollBox.scrollTop + scrollBox.clientHeight >=
           scrollBox.scrollHeight - lastNodeHeight / 2;
  }
function Utils_isOutputScrolledToBottom ( aOutputNode ) { let lastNodeHeight = aOutputNode . lastChild ? aOutputNode . lastChild . clientHeight : 0 ; let scrollBox = aOutputNode . scrollBoxObject . element ; return scrollBox . scrollTop + scrollBox . clientHeight >= scrollBox . scrollHeight - lastNodeHeight / 2 ; }
Check if the given output node is scrolled to the bottom.
Check if the given output node is scrolled to the bottom .