B2G/gecko/browser/devtools/scratchpad/scratchpad.js
/**
   * The Scratchpad window unload event handler. This method unloads/destroys
   * the source editor.
   *
   * @param nsIDOMEvent aEvent
   */
The Scratchpad window unload event handler. This method unloads/destroys
the source editor.


The Scratchpad window unload event handler . This method unloads / destroys the source editor .
function SP_onUnload(aEvent)
  {
    if (aEvent.target != document) {
      return;
    }
    this.resetContext();
    this.gBrowser.selectedBrowser.removeEventListener("load",
        this._reloadAndRunEvent, true);
    this.editor.removeEventListener(SourceEditor.EVENTS.DIRTY_CHANGED,
                                    this._onDirtyChanged);
    PreferenceObserver.uninit();
    this.editor.destroy();
    this.editor = null;
    this.initialized = false;
  }
function SP_onUnload ( aEvent ) { if ( aEvent . target != document ) { return ; } this . resetContext ( ) ; this . gBrowser . selectedBrowser . removeEventListener ( "load" , this . _reloadAndRunEvent , true ) ; this . editor . removeEventListener ( SourceEditor . EVENTS . DIRTY_CHANGED , this . _onDirtyChanged ) ; PreferenceObserver . uninit ( ) ; this . editor . destroy ( ) ; this . editor = null ; this . initialized = false ; }
The Scratchpad window unload event handler.
The Scratchpad window unload event handler .