Hi all,
I have a form whereby other fields are hidden/showed, enabled/disabled based on another field.
The show hide is controlled by setShowIfCondition() method..
	The enable/disable is controlled via a changedEvent...
	This works fine most of the time, however where there are SelectItem fields, I have added a clear picker icon in order to clear the value...
	By calling clearValue(), the update event is not fired. Not sure if this is a bug, if so, maybe it's fixed in a newer version, but for now, is there a way in the method that is called by the clear icon to manually fire the field update event?
Thanks,
Dale
Smart GWT Version : 4.0p
Smart GWT Build Date : Mon Dec 23 10:04:00 GMT 2013
GWT Version : 2.4.0
					I have a form whereby other fields are hidden/showed, enabled/disabled based on another field.
The show hide is controlled by setShowIfCondition() method..
Code:
	
	                effectedField.setShowIfCondition(new FormItemIfFunction() {
                    @Override
                    public boolean execute(FormItem item, Object o, DynamicForm dynamicForm) {
                        String dependantFieldValue = FormUtil.getStringValue(dependantField);
                        return isConditionMet(dependantFieldValue, definitionDto.getShowIfOperator(), definitionDto.getShowIfValue());
                    }
                });
Code:
	
	                dependantField.addChangedHandler(new ChangedHandler() {
                    @Override
                    public void onChanged(ChangedEvent changedEvent) {
                        String dependantFieldValue = FormUtil.getStringValue(dependantField);
                        effectedField.setDisabled(isConditionMet(dependantFieldValue, definitionDto.getDisableIfOperator(), definitionDto.getDisableIfValue()));
                    }
                });
Code:
	
	                    selectItem.setIcons(new PickerIcon(PickerIcon.CLEAR, new FormItemClickHandler() {
                        @Override
                        public void onFormItemClick(FormItemIconClickEvent formItemIconClickEvent) {
                            formItemIconClickEvent.getItem().clearValue();
                            
                        }
                    }));
Thanks,
Dale
Smart GWT Version : 4.0p
Smart GWT Build Date : Mon Dec 23 10:04:00 GMT 2013
GWT Version : 2.4.0