« XUL Reference home
swapDocShells( otherBrowser )
Return type: no return value
Swaps the content, history and current state of this browser with another browser. During the swap, pagehide and pageshow events are fired on both browsers. This method can be used to move browser between windows or tear off a browser into a new window.

Note: Both browsers must be either standalone browsers or embedded in a tabbrowser. You can't mix them.