rem:  var windowManager = Components.classes["@mozilla.org/appshell/window-mediator;1"] .getService(Components.interfaces.nsIWindowMediator);  var bookmarksWindow = windowManager.getMostRecentWindow("bookmarks:manager");  if (bookmarksWindow) { bookmarksWindow.focus(); } else {  if (!gDisableBookmarks) { gDisableBookmarks = true;  open("chrome: "chrome,extrachrome,menubar,resizable,scrollbars,status,toolbar"); setTimeout(enableBookmarks, 2000); } } 
add: toOpenWindowByType("bookmarks:manager", "chrome: 
context: function BrowserEditBookmarks(){  // Use a single sidebar bookmarks dialog  var windowManager = Components.classes["@mozilla.org/appshell/window-mediator;1"]                                .getService(Components.interfaces.nsIWindowMediator);  var bookmarksWindow = windowManager.getMostRecentWindow("bookmarks:manager");  if (bookmarksWindow) {    bookmarksWindow.focus();  } else {    // while disabled, don't open new bookmarks window    if (!gDisableBookmarks) {      gDisableBookmarks = true;      open("chrome://communicator/content/bookmarks/bookmarksManager.xul", "_blank",        "chrome,extrachrome,menubar,resizable,scrollbars,status,toolbar");      setTimeout(enableBookmarks, 2000);    }  }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/22b00d4d803228b55f5ac0fee2a61333a8aa9eec/navigator.js/clean/suite/browser/navigator.js