I have Class which extends a Form and it implements Property.ValueChangeListenter
like this:
public class AddressForm extends Form implements ClickListener, Property.ValueChangeListener
.
.
.
_zipCode = (TextField) getField(“zipcode”);
_zipCode.addListener(this);
_zipCode.setImmediate(true);
and the following valueChange method
@Override
public void valueChange(Property.ValueChangeEvent event) {
Property property = event.getProperty();
if(property == _zipCode) {
updateZipCity();
}
}
Everything works fine until I call setFormFieldFactory(new AddressFieldFactory()); method
After I call that method the valueChange event never fires again even if I don’t change the zipcode field in the AddressFieldFactory().
What am I doing wrong?
Thank You
Peter