Public feed
#378985
function rem(toremove){ var splash_cur_PrefBranchPrefix = "profile.splash." + toremove;//alert(splash_cur_PrefBranchPrefix); var prefService = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefService); var nsIPrefBranchObj = prefService.getBranch(splash_cur_PrefBranchPrefix); var prefCount = {value:0}; var prefArray = nsIPrefBranchObj.getChildList("" , prefCount); var branchService = nsPreferences.mPrefService; for (var i = 0; i < prefArray.length; ++i) { if (branchService.prefHasUserValue(splash_cur_PrefBranchPrefix + prefArray[i])) { branchService.clearUserPref(splash_cur_PrefBranchPrefix + prefArray[i]); } } var splashtestname2 = nsPreferences.copyUnicharPref("profile.list.splash"); var splashtestparsed2 = splashtestname2.split(";"); for (i=0; i<splashtestparsed2.length; i++) { if (!(splashtestparsed2[i]==toremove)) { var newpref=splashtestparsed2[i]+";"; } }//alert(newpref); nsPreferences2.setCharPref("profile.list.splash", newpref); window.location.reload();}