B2G/gecko/browser/devtools/scratchpad/scratchpad.js
/**
   * The Source Editor DirtyChanged event handler. This function updates the
   * Scratchpad window title to show an asterisk when there are unsaved changes.
   *
   * @private
   * @see SourceEditor.EVENTS.DIRTY_CHANGED
   * @param object aEvent
   *        The DirtyChanged event object.
   */
The Source Editor DirtyChanged event handler. This function updates the
Scratchpad window title to show an asterisk when there are unsaved changes.

@private
@see SourceEditor.EVENTS.DIRTY_CHANGED
@param object aEvent
The DirtyChanged event object.
The Source Editor DirtyChanged event handler . This function updates the Scratchpad window title to show an asterisk when there are unsaved changes . @private @see SourceEditor . EVENTS . DIRTY_CHANGED @param object aEvent The DirtyChanged event object .
function SP__onDirtyChanged(aEvent)
  {
    Scratchpad._updateTitle();
    if (Scratchpad.filename) {
      if (Scratchpad.editor.dirty) {
        document.getElementById("sp-cmd-revert").removeAttribute("disabled");
      }
      else {
        document.getElementById("sp-cmd-revert").setAttribute("disabled", true);
      }
    }
  }
function SP__onDirtyChanged ( aEvent ) { Scratchpad . _updateTitle ( ) ; if ( Scratchpad . filename ) { if ( Scratchpad . editor . dirty ) { document . getElementById ( "sp-cmd-revert" ) . removeAttribute ( "disabled" ) ; } else { document . getElementById ( "sp-cmd-revert" ) . setAttribute ( "disabled" , true ) ; } } }
The Source Editor DirtyChanged event handler.
The Source Editor DirtyChanged event handler .