rem: setLabelForNode(newButton, string); 
add: setLabelForNode(firstButton, string); 
context: function commonDialogOnLoad(){  // set the window title  window.title = gCommonDialogParam.GetString(12);  // set the number of command buttons  var nButtons = gCommonDialogParam.GetInt(2);  var dialog = document.documentElement;  switch (nButtons) {    case 1:      dialog.getButton("cancel").hidden = true;      break;    case 4:      dialog.getButton("extra2").hidden = false;    case 3:      dialog.getButton("extra1").hidden = false;  }  // display the main text  var messageText = gCommonDialogParam.GetString(0);  var messageParent = document.getElementById("info.box");  var messageParagraphs = messageText.split("\n");  for (var i = 0; i < messageParagraphs.length; i++) {    var descriptionNode = document.createElement("description");    var text = document.createTextNode(messageParagraphs[i]);    descriptionNode.appendChild(text);    messageParent.appendChild(descriptionNode);  }  setElementText("info.header", gCommonDialogParam.GetString(3), true);  // set the icon  var iconElement = document.getElementById("info.icon");  var iconClass = gCommonDialogParam.GetString(2);  if (!iconClass)    iconClass = "message-icon";  iconElement.setAttribute("class", iconElement.getAttribute("class") + " " + iconClass);  var firstButton = null;  var newButton;  switch (nButtons) {    case 4:      setLabelForNode(firstButton = document.documentElement.getButton("extra2"),                       gCommonDialogParam.GetString(11));                     // fall through    case 3:      newButton = document.documentElement.getButton("extra1");      firstButton = firstButton || newButton;      setLabelForNode(newButton, gCommonDialogParam.GetString(10));      // fall through    default:    case 2:      newButton = document.documentElement.getButton("accept");      firstButton = firstButton || newButton;      var string = gCommonDialogParam.GetString(8);      if (string)        setLabelForNode(newButton, string);      // fall through    case 1:      newButton = document.documentElement.getButton("cancel");      firstButton = firstButton || newButton;      string = gCommonDialogParam.GetString(9);      if (string)        setLabelForNode(newButton, string);      break;  }  // set default result to cancelled  gCommonDialogParam.SetInt(0, 1);   // initialize the checkbox  if (setCheckbox(gCommonDialogParam.GetString(1), gCommonDialogParam.GetInt(1)) &&      gCommonDialogParam.GetInt(3) == 0)  // if no text fields    firstButton.focus(); // Don't focus checkbox, focus first button instead  getAttention();}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/0c0a6ffa8e7f6a9cbd43c7b0a19e5957f556fdd9/commonDialog.js/buggy/xpfe/global/resources/content/commonDialog.js