rem: treeroot.appendChild(item);  
add: tree_root.appendChild(item);  
context: function add_node_to_current_list(registry, service){  debug("Adding "+service.Value);  // Copy out the attributes we want  var option_title     = get_attr(registry, service, 'title');  var option_customize = get_attr(registry, service, 'customize');  var option_content   = get_attr(registry, service, 'content');  var tree     = document.getElementById('current-panels');  var treeroot = document.getElementById('current-panels-root');  // Check to see if the panel already exists...  for (var ii = treeroot.firstChild; ii != null; ii = ii.nextSibling) {    if (ii.getAttribute('id') == service.Value) {      // The panel is already in the current panel list.      // Avoid adding it twice.      tree.selectItem(ii);      tree.ensureElementIsVisible(ii);      return;    }  }  // Create a treerow for the new panel  var item = document.createElement('treeitem');  var row  = document.createElement('treerow');  var cell = document.createElement('treecell');  // Copy over the attributes  item.setAttribute('id', service.Value);  if (option_customize && option_customize != '') {    item.setAttribute('customize', option_customize);  }  item.setAttribute('content', option_content);  cell.setAttribute('class', 'treecell-indent treecell-panel');  cell.setAttribute('label', option_title);  // Add it to the current panels tree  item.appendChild(row);  row.appendChild(cell);  treeroot.appendChild(item);  // Select is only if the caller wants to.  tree.selectItem(item);  tree.ensureElementIsVisible(item);}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/a376ddc0531725ad80728692bef9c8ab8b17636c/customize.js/buggy/suite/common/sidebar/customize.js