Program: 73029
Project: 73029
Buggy source:
/** 
 * React to a change in an attribute.  This method updates the local data structure provided by   {@link #getExportParameters()}.
 * @param attribute The attribute that changed.
 * @exception IllegalActionException If the change is not acceptableto this container (not thrown in this base class).
 */
public void attributeChanged(Attribute attribute) throws IllegalActionException {
  if (attribute == backgroundColor) {
    _parameters.backgroundColor=backgroundColor.asColor();
  }
 else   if (attribute == copyJavaScriptFiles) {
    _parameters.copyJavaScriptFiles=((BooleanToken)copyJavaScriptFiles.getToken()).booleanValue();
  }
 else   if (attribute == directoryToExportTo) {
    _parameters.directoryToExportTo=directoryToExportTo.asFile();
  }
 else   if (attribute == imageFormat) {
    _parameters.imageFormat=imageFormat.stringValue();
  }
 else   if (attribute == openCompositesBeforeExport) {
    _parameters.openCompositesBeforeExport=((BooleanToken)openCompositesBeforeExport.getToken()).booleanValue();
  }
 else   if (attribute == runBeforeExport) {
    _parameters.runBeforeExport=((BooleanToken)runBeforeExport.getToken()).booleanValue();
  }
 else   if (attribute == showInBrowser) {
    _parameters.showInBrowser=((BooleanToken)showInBrowser.getToken()).booleanValue();
  }
 else   if (attribute == usePtWebsite) {
    _parameters.usePtWebsite=((BooleanToken)usePtWebsite.getToken()).booleanValue();
  }
 else {
    super.attributeChanged(attribute);
  }
}

Fixed version (ground truth):
/** 
 * React to a change in an attribute.  This method updates the local data structure provided by   {@link #getExportParameters()}.
 * @param attribute The attribute that changed.
 * @exception IllegalActionException If the change is not acceptableto this container (not thrown in this base class).
 */
public void attributeChanged(Attribute attribute) throws IllegalActionException {
  if (attribute == backgroundColor) {
    if (!backgroundColor.getExpression().trim().equals("String_Node_Str")) {
      _parameters.backgroundColor=backgroundColor.asColor();
    }
 else {
      _parameters.backgroundColor=BasicGraphFrame.BACKGROUND_COLOR;
    }
  }
 else   if (attribute == copyJavaScriptFiles) {
    _parameters.copyJavaScriptFiles=((BooleanToken)copyJavaScriptFiles.getToken()).booleanValue();
  }
 else   if (attribute == directoryToExportTo) {
    _parameters.directoryToExportTo=directoryToExportTo.asFile();
  }
 else   if (attribute == imageFormat) {
    _parameters.imageFormat=imageFormat.stringValue();
  }
 else   if (attribute == openCompositesBeforeExport) {
    _parameters.openCompositesBeforeExport=((BooleanToken)openCompositesBeforeExport.getToken()).booleanValue();
  }
 else   if (attribute == runBeforeExport) {
    _parameters.runBeforeExport=((BooleanToken)runBeforeExport.getToken()).booleanValue();
  }
 else   if (attribute == showInBrowser) {
    _parameters.showInBrowser=((BooleanToken)showInBrowser.getToken()).booleanValue();
  }
 else   if (attribute == usePtWebsite) {
    _parameters.usePtWebsite=((BooleanToken)usePtWebsite.getToken()).booleanValue();
  }
 else {
    super.attributeChanged(attribute);
  }
}