B2G/gecko/testing/marionette/marionette-server.js
/**
   * Switches to the global ChromeMessageBroadcaster, potentially replacing a frame-specific
   * ChromeMessageSender.  Has no effect if the global ChromeMessageBroadcaster is already
   * in use.  If this replaces a frame-specific ChromeMessageSender, it removes the message
   * listeners from that sender, and then puts the corresponding frame script "to sleep",
   * which removes most of the message listeners from it as well.
   */
Switches to the global ChromeMessageBroadcaster, potentially replacing a frame-specific
ChromeMessageSender.  Has no effect if the global ChromeMessageBroadcaster is already
in use.  If this replaces a frame-specific ChromeMessageSender, it removes the message
listeners from that sender, and then puts the corresponding frame script "to sleep",
which removes most of the message listeners from it as well.
Switches to the global ChromeMessageBroadcaster potentially replacing a frame - specific ChromeMessageSender . Has no effect if the global ChromeMessageBroadcaster is already in use . If this replaces a frame - specific ChromeMessageSender it removes the message listeners from that sender and then puts the corresponding frame script " to sleep " which removes most of the message listeners from it as well .
function MDA_switchToGlobalMM() {
    if (this.currentRemoteFrame !== null) {
      this.removeMessageManagerListeners(this.messageManager);
      this.sendAsync("sleepSession", null, null, true);
    }
    this.messageManager = this.globalMessageManager;
    this.currentRemoteFrame = null;
  }
function MDA_switchToGlobalMM ( ) { if ( this . currentRemoteFrame !== null ) { this . removeMessageManagerListeners ( this . messageManager ) ; this . sendAsync ( "sleepSession" , null , null , true ) ; } this . messageManager = this . globalMessageManager ; this . currentRemoteFrame = null ; }
Switches to the global ChromeMessageBroadcaster, potentially replacing a frame-specific
 ChromeMessageSender.
Switches to the global ChromeMessageBroadcaster potentially replacing a frame - specific ChromeMessageSender .