rem: var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService(); var windowManagerInterface = windowManager.QueryInterface(Components.interfaces.nsIWindowMediator); var searchWindow = windowManagerInterface.getMostRecentWindow("mailnews:search"); 
context: function MsgSearchMessages(){    var preselectedFolder = null;    if ("GetFirstSelectedMsgFolder" in window)      preselectedFolder = GetFirstSelectedMsgFolder();    var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService();    var windowManagerInterface = windowManager.QueryInterface(Components.interfaces.nsIWindowMediator);    var searchWindow = windowManagerInterface.getMostRecentWindow("mailnews:search");    if (searchWindow)        searchWindow.focus();    else        window.openDialog("chrome://messenger/content/SearchDialog.xul", "",                           "chrome,resizable,status,centerscreen,dialog=no", { folder: preselectedFolder });}
meta: 5459	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5459/2648c596d995e1d4d6e78138108ab573c98916f7/mailWindowOverlay.js/clean/mailnews/base/resources/content/mailWindowOverlay.js