rem: profileList.selectItem(previous); profileList.ensureElementIsVisible(previous); 
add: profileList.view.selection.select(previous); profileList.treeBoxObject.ensureRowIsVisible(previous); 
context: function DeleteProfile(deleteFiles){  var profileList = document.getElementById("profiles");  if (profileList.selectedItems && profileList.selectedItems.length) {    var selected = profileList.selectedItems[0];    var name = selected.getAttribute("rowName");    var previous = profileList.getPreviousItem(selected, 1);    try {      profile.deleteProfile(name, deleteFiles);      profileList.removeChild(selected);      if (previous) {        profileList.selectItem(previous);        profileList.ensureElementIsVisible(previous);      }      // set the button state      DoEnabling();    }    catch (ex) {      dump("Exception during profile deletion.\n");    }  }}
meta: 5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5872/d31ec2cc59008424497c5e0de725e40ae1367bcd/profileManager.js/clean/profile/resources/content/profileManager.js