Hello,
with the 3.1p 2013/01/28 LGPL I get an error, if I try to access a hidden FormItem after the Form is drawn. Here is the TestCase:
and here is the error from the GWT-Console:
regards Andreas
with the 3.1p 2013/01/28 LGPL I get an error, if I try to access a hidden FormItem after the Form is drawn. Here is the TestCase:
Code:
DataSource ds = new DataSource(); DataSourceField foo = new DataSourceField("foo", FieldType.TEXT); foo.setHidden(true); ds.setFields(foo); final DynamicForm form = new DynamicForm(); form.setDataSource(ds); form.setUseAllDataSourceFields(true); form.setFields(new FormItem("foo")); System.out.println(form.getField("foo")); // WORKS form.draw(); System.out.println(form.getField("foo")); // ERROR
Code:
com.google.gwt.core.client.JavaScriptException: (TypeError): self is null at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:248) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136) at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561) at com.google.gwt.dev.shell.ModuleSpace.invokeNativeBoolean(ModuleSpace.java:184) at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeBoolean(JavaScriptHost.java:35) at com.smartgwt.client.widgets.form.fields.FormItem.isCreated(FormItem.java) at com.smartgwt.client.widgets.form.fields.FormItem.getAttributeAsString(FormItem.java:4226) at com.smartgwt.client.widgets.form.fields.FormItem.getName(FormItem.java:4389) at com.smartgwt.client.widgets.form.DynamicForm.getField(DynamicForm.java:3286) ....
Comment