title: How to know loaded window is Firefox Electrolysis Window
body: <p>I want to code a functionality for Firefox Electrolysis window. But how can I know loaded window is Firefox Electrolysis window but not the normal Firefox window?</p>
  
  <pre><code>var WindowListener = {
      setupBrowserUI: function(window) {
          //
      },
      tearDownBrowserUI: function(window) {
      },
      // nsIWindowMediatorListener functions
      onOpenWindow: function(xulWindow) {
          var domWindow = xulWindow.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
                                   .getInterface(Components.interfaces.nsIDOMWindow);
          // Wait for it to finish loading
          domWindow.addEventListener("load", function listener() {
              domWindow.removeEventListener("load", listener, false);
              // If this is a browser window then setup its UI      
              if (domWindow.document.documentElement.getAttribute("windowtype")=="navigator:browser") {
  
                      //how to know domWindow is Firefox Electrolysis window
  
              }
  
          }, false);
      },
      onCloseWindow: function(xulWindow) {
      },
      onWindowTitleChange: function(xulWindow, newTitle) {
      }
  };
  
  let wm = Components.classes["@mozilla.org/appshell/window-mediator;1"].
         getService(Components.interfaces.nsIWindowMediator);
  // Wait for any new browser windows to open
  wm.addListener(WindowListener);
  </code></pre>
  
  <p>You can use the code in Scratchpad. The comment</p>
  
  <pre><code>//how to know domWindow is Firefox Electrolysis window
  </code></pre>
  
  <p>is the place that I need to detect loaded window is Firefox Electrolysis window but not the normal Firefox window.</p>