I'm using the nightly build of SmartGWTEE from yesterday.
I wanted to have a SelectItem or ComboItem and an "+" Icon to create a new element. This does not work. It seems that the IconClickHandler is called when you click the SelectItem dropdown arrow as well as the Icon. This seems like a bug to me.
Adapted from example: http://www.smartclient.com/smartgwt/showcase/#form_details_icons
I wanted to have a SelectItem or ComboItem and an "+" Icon to create a new element. This does not work. It seems that the IconClickHandler is called when you click the SelectItem dropdown arrow as well as the Icon. This seems like a bug to me.
Adapted from example: http://www.smartclient.com/smartgwt/showcase/#form_details_icons
Code:
public void onModuleLoad() {
final DynamicForm form = new DynamicForm();
form.setWidth(200);
FormItemIcon icon = new FormItemIcon();
icon.setSrc("[SKIN]/actions/help.png");
final SelectItem severityLevel = new SelectItem();
severityLevel.setName("severityLevel");
severityLevel.setTitle("Severity Level");
severityLevel.setDefaultValue("Severity 2");
severityLevel.setIcons(icon);
severityLevel.addIconClickHandler(new IconClickHandler() {
public void onIconClick(IconClickEvent event) {
SC.say(HELPTEXT);
}
});
form.setFields(severityLevel);
form.draw();
}
Comment