rem: const kPrefContractID = "@mozilla.org/preferences;1"; const kPrefIID = Components.interfaces.nsIPref; const kPrefSvc = Components.classes[kPrefContractID].getService(kPrefIID); var showDialog = true; try { showDialog = !kPrefSvc.GetBoolPref("browser.bookmarks.add_without_dialog"); } catch (e) { }  if (showDialog) 
add: if (aShowDialog) 
context:   addBookmark: function (aURL, aTitle, aCharset)  {    if (aCharset === undefined) {      var fw = document.commandDispatcher.focusedWindow;      aCharset = fw.document.characterSet;    }      const kPrefContractID = "@mozilla.org/preferences;1";    const kPrefIID = Components.interfaces.nsIPref;    const kPrefSvc = Components.classes[kPrefContractID].getService(kPrefIID);    var showDialog = true;    try {      showDialog = !kPrefSvc.GetBoolPref("browser.bookmarks.add_without_dialog");    }    catch (e) {    }    if (showDialog)      openDialog("chrome://communicator/content/bookmarks/addBookmark.xul", "",                  "centerscreen,chrome,dialog=no,resizable=no", aTitle, aURL, null, aCharset);    else {      // User has elected to override the file dialog and always file bookmarks      // into the default bookmark folder.       const kBMSvcContractID = "@mozilla.org/browser/bookmarks-service;1";      const kBMSvcIID = Components.interfaces.nsIBookmarksService;      const kBMSvc = Components.classes[kBMSvcContractID].getService(kBMSvcIID);      kBMSvc.AddBookmark(aURL, aTitle, kBMSvcIID.BOOKMARK_DEFAULT_TYPE, aCharset);    }  }
meta: 5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5872/3c1e4cee57d48dad81a4af4b045f5845fa04b0f0/bookmarksOverlay.js/clean/xpfe/components/bookmarks/resources/bookmarksOverlay.js