add:   NoDefault = window.arguments[1].NoDefault; if (NoDefault) {  document.getElementById("DefaultColorButton").setAttribute("collapsed","true"); } 
context: function Startup(){  if (!InitEditorShell() || !window.arguments[1])  {    dump("EdColorPicker: Failed to get EditorShell or arguments[1]\n");    return;  }  // Create dialog object to store controls for easy access  dialog = new Object;  dialog.ColorPicker      = document.getElementById("ColorPicker");  dialog.ColorInput       = document.getElementById("ColorInput");  dialog.LastPickedButton = document.getElementById("LastPickedButton");  dialog.LastPickedColor  = document.getElementById("LastPickedColor");  dialog.TableRadio       = document.getElementById("TableRadio");  dialog.CellRadio        = document.getElementById("CellRadio");  dialog.Ok               = document.getElementById("ok");  dialog.ColorSwatch      = document.getElementById("ColorPickerSwatch");    // The type of color we are setting:   //    Text, or background: Page, Table, or Cell  ColorType = window.arguments[1].Type;  dialog.ColorInput.value = "";  var color = "";  // window.arguments[1] is object to set initial and return color  switch (ColorType)  {    case "Page":      window.title = GetString("PageBackgroundColor");      if (window.arguments[1].PageColor)        color = window.arguments[1].PageColor;      break;    case "Table":      window.title = GetString("TableBackgroundColor");      if (window.arguments[1].TableColor)        color = window.arguments[1].TableColor;      break;    case "Cell":      window.title = GetString("CellBackgroundColor");      if (window.arguments[1].CellColor)        color = window.arguments[1].CellColor;      break;    case "TableOrCell":      TableOrCell = true;      document.getElementById("TableOrCellGroup").setAttribute("collapsed", "false");      window.title = GetString("TableOrCellColor");      if (window.arguments[1].TableColor)      {        color = window.arguments[1].TableColor;        dialog.TableRadio.checked = true;      }      else       {        if (window.arguments[1].CellColor)          color = window.arguments[1].CellColor;        dialog.CellRadio.checked = true;      }      break;    default:      window.title = GetString("TextColor");      if (window.arguments[1].TextColor)        color = window.arguments[1].TextColor;      break;  }  SetCurrentColor(color)  if (ColorType == "Text")    LastPickedColor = dialog.LastPickedColor.getAttribute("LastTextColor");  else    LastPickedColor = dialog.LastPickedColor.getAttribute("LastBackgroundColor");dump("LastPickedColor = "+LastPickedColor+"|\n");  dialog.LastPickedColor.setAttribute("style","background-color: "+LastPickedColor);  doSetOKCancel(onOK, onCancel);  // Set method to detect clicking on OK button  //  so we don't get fooled by changing "default" behavior  dialog.Ok.setAttribute("onclick", "onOKClick()");  // Make the "Last-picked" the default button  //  until the user selects a color    dialog.Ok.removeAttribute("default");  dialog.LastPickedButton.setAttribute("default","true");  SetTextfieldFocus(dialog.ColorInput);  SetWindowLocation();}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/49bc32c783f8e8fbf15d440f1587990451b05b6f/EdColorPicker.js/buggy/editor/ui/dialogs/content/EdColorPicker.js