rem: const kPrefSvcContractID = "@mozilla.org/preferences;1"; const kPrefSvcIID = Components.interfaces.nsIPref; 
add: const kPrefSvcContractID = "@mozilla.org/preferences-service;1"; const kPrefSvcIID = Components.interfaces.nsIPrefService; 
context: function Startup(){  gData = parent.hPrefWindow.wsm.dataManager.pageData["chrome://communicator/content/pref/pref-themes.xul"];  var list = document.getElementById( "skinsList" );  if ("loaded" in gData && "themeIndex" in gData) {    list.selectedIndex = gData.themeIndex;        return;  }  gData.loaded = true;  parent.hPrefWindow.registerOKCallbackFunc( applySkin );  const kPrefSvcContractID = "@mozilla.org/preferences;1";  const kPrefSvcIID = Components.interfaces.nsIPref;  const kPrefSvc = Components.classes[kPrefSvcContractID].getService(kPrefSvcIID);  var theme = null;  try {    theme = kPrefSvc.getComplexValue("general.skins.selectedSkin",                                     Components.interfaces.nsISupportsString).data;  } catch (e) {  }  var matches;  for (var i = 0; i < list.childNodes.length; ++i) {    var child = list.childNodes[i];    var name = child.getAttribute("name");    if (name) {      if (!theme)        matches = chromeRegistry.isSkinSelected(name, true) == Components.interfaces.nsIChromeRegistry.FULL;      else        matches = name == theme;      if (matches) {        list.selectItem(child);        break;      }    }        }  var navbundle = document.getElementById("bundle_navigator");  var showSkinsDescription = navbundle.getString("showskinsdescription");  if( showSkinsDescription == "false" )  {    gShowDescription = false;    var description = document.getElementById("description");    while (description.hasChildNodes())      description.removeChild(description.firstChild);  }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/1e91454344482648806ba1a633c0f0ed415fce82/pref-themes.js/clean/xpfe/components/prefwindow/resources/content/pref-themes.js