rem: selectedSkin = kPrefSvc.CopyCharPref("general.skins.selectedSkin"); 
add: selectedSkin = kPrefSvc.getComplexValue("general.skins.selectedSkin", Components.interfaces.nsISupportsString).data; 
context: function themeSelect(){  var list = document.getElementById("skinsList");  if (!list)    return;  var prefbundle = document.getElementById("bundle_prefutilities");  var selectedItem = list.selectedItems.length ? list.selectedItems[0] : null;  if (selectedItem && selectedItem.getAttribute("skin") == "true") {    var themeName = selectedItem.getAttribute("displayName");    var skinName = selectedItem.getAttribute("name");    gData.name = skinName;    gData.themeIndex = list.selectedIndex;    var oldTheme;    try {      oldTheme = !chromeRegistry.checkThemeVersion(skinName);    }    catch(e) {      oldTheme = false;    }    var nameField = document.getElementById("displayName");    var author = document.getElementById("author");    var image = document.getElementById("previewImage");    var descText = document.createTextNode(selectedItem.getAttribute("description"));    var description = document.getElementById("description");    var uninstallButton = document.getElementById("uninstallSkin");    var uninstallLabel = prefbundle.getString("uninstallThemePrefix");    while (description.hasChildNodes())      description.removeChild(description.firstChild);    nameField.setAttribute("value", themeName);    author.setAttribute("value", selectedItem.getAttribute("author"));    image.setAttribute("src", selectedItem.getAttribute("image"));    // XXX - this sucks and should only be temporary.    var selectedSkin = "";    try {      const kPrefSvcContractID = "@mozilla.org/preferences;1";      const kPrefSvcIID = Components.interfaces.nsIPref;      const kPrefSvc = Components.classes[kPrefSvcContractID].getService(kPrefSvcIID);      selectedSkin = kPrefSvc.CopyCharPref("general.skins.selectedSkin");    }    catch (e) {    }    if (!oldTheme) {          if( gShowDescription )         description.appendChild(descText);      var locType = selectedItem.getAttribute("loctype");      uninstallButton.disabled = (selectedSkin == skinName) || (locType == "install");            uninstallLabel = uninstallLabel.replace(/%theme_name%/, themeName);      uninstallButton.label = uninstallLabel;    }    else {      var brandbundle = document.getElementById("bundle_brand");      uninstallLabel = uninstallLabel.replace(/%theme_name%/, themeName);      uninstallButton.label = uninstallLabel;      uninstallButton.disabled = selectedSkin == skinName;      var newText = prefbundle.getString("oldTheme");      newText = newText.replace(/%theme_name%/, themeName);            newText = newText.replace(/%brand%/g, brandbundle.getString("brandShortName"));      if( gShowDescription )  {        descText = document.createTextNode(newText);        description.appendChild(descText);      }    }  }  else {    uninstallButton.disabled = true;    gData.name = null;  }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/2460a5087c9598728242b4ed723fe279359c634f/pref-themes.js/buggy/suite/common/pref/pref-themes.js