Hello,
I'm using smartgwt LGPL 3.1p 20130530 (nightly).
When using a custom CanvasItem, which stores its value via CanvasItem::storeValue(), I get the following error after changing the value of the item:
this is the code for reproducing the error:
regards
Andreas
I'm using smartgwt LGPL 3.1p 20130530 (nightly).
When using a custom CanvasItem, which stores its value via CanvasItem::storeValue(), I get the following error after changing the value of the item:
Code:
Uncaught exception escaped : com.google.gwt.event.shared.UmbrellaException Exception caught: Exception caught: (TypeError) @com.smartgwt.client.widgets.form.fields.CanvasItem::storeValue(Ljava/lang/Object;)([string: '4567897']): self.storeValue is not a function
Code:
public void onModuleLoad() {
ListGrid lg = new ListGrid();
lg.setWidth100();
lg.setHeight100();
lg.setEditorCustomizer(new ListGridEditorCustomizer() {
@Override
public FormItem getEditor(ListGridEditorContext context) {
if ("foo".equals(context.getEditField().getName())) {
return new CanvasItem() {
{
setShouldSaveValue(true);
TextArea input = new TextArea();
setCanvas(new WidgetCanvas(input));
input.addValueChangeHandler(new ValueChangeHandler<String>() {
@Override
public void onValueChange(ValueChangeEvent<String> event) {
// self.storeValue is not a function
storeValue(event.getValue());
}
});
}
};
}
return context.getDefaultProperties();
}
});
lg.setFields(new ListGridField("foo"), new ListGridField("bar"));
lg.startEditingNew();
lg.setCanEdit(true);
lg.draw();
}
Andreas
Comment