Add a new home property to a change listener
Code: Select all
this.home.addPropertyChangeListener(Home.Property.valueOf(ENHANCED_EXTERNAL_BRIGHTNESS),
new PropertyChangeListener() {
public void propertyChange(PropertyChangeEvent ev) {
isEnhancedExternalBrightness = Boolean.parseBoolean(home.getProperty(ENHANCED_EXTERNAL_BRIGHTNESS));
externalBrightnessEnabledCheckBox.setSelected(isEnhancedExternalBrightness);
}
});Code: Select all
Exception in thread "AWT-EventQueue-0" java.lang.IllegalArgumentException: No enum constant com.eteks.sweethome3d.model.Home.Property.enhancedExternalBrightness