rem: while (!win.toolbar.visible) { 
add: while (win.document.documentElement.getAttribute("chromehidden")) { 
context: function getMostRecentBrowserWindow() {  var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]                     .getService(Components.interfaces.nsIWindowMediator);#ifdef BROKEN_WM_Z_ORDER  var win = wm.getMostRecentWindow("navigator:browser", true);  // if we're lucky, this isn't a popup, and we can just return this  if (win && !win.toolbar.visible) {    var windowList = wm.getEnumerator("navigator:browser", true);    // this is oldest to newest, so this gets a bit ugly    while (windowList.hasMoreElements()) {      var nextWin = windowList.getNext();      if (nextWin.toolbar.visible)        win = nextWin;    }  }#else  var windowList = wm.getZOrderDOMWindowEnumerator("navigator:browser", true);  if (!windowList.hasMoreElements())    return null;  var win = windowList.getNext();  while (!win.toolbar.visible) {    if (!windowList.hasMoreElements())       return null;    win = windowList.getNext();  }#endif  return win;}
meta: 10520	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/10520/7e9a73833034383a174162f0e964c6d9072fe826/nsBrowserContentHandler.js/clean/browser/components/nsBrowserContentHandler.js