The following example used to work fine in the past:
package org.yournamehere.client;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.i18n.client.NumberFormat;
import com.smartgwt.client.core.DataClass;
import com.smartgwt.client.data.Record;
import com.smartgwt.client.data.SimpleType;
import com.smartgwt.client.data.SimpleTypeFormatter;
import com.smartgwt.client.types.FieldType;
import com.smartgwt.client.widgets.DataBoundComponent;
public class MainEntryPoint implements EntryPoint {
public MainEntryPoint() {
}
public void onModuleLoad() {
final NumberFormat amountFormat = NumberFormat.getFormat("###,###.###");
SimpleType amountType = new SimpleType("amount", FieldType.FLOAT);
amountType.setNormalDisplayFormatter(new SimpleTypeFormatter() {
@Override
public String format(Object value, DataClass field,
DataBoundComponent component, Record record) {
return amountFormat.format(Double.valueOf(value.toString()));
}
});
}
}
Now in svn 1141, the GWT console shows exception:
00:00:19,248 [ERROR] Unable to load module entry point class org.yournamehere.client.MainEntryPoint (see associated exception for details)
com.google.gwt.core.client.JavaScriptException: (ReferenceError): $debox is not defined fileName: http://localhost:8080 lineNumber: 17 stack: ([object GWTJavaObject])@http://localhost:8080:17 connect("http://localhost:8080/TestSimpleType/?gwt.codesvr=127.0.0.1:9997","7+uvi0w_r;&`=x8@","127.0.0.1:9997","org.yournamehere.Main","2.0")@:0 ((void 0),"org.yournamehere.Main","http://localhost:8080/TestSimpleType/")@http://localhost:8080/TestSimpleType/hosted.html?org_yournamehere_Main:264 z()@http://localhost:8080/TestSimpleType/org.yournamehere.Main.nocache.js:2 (-6)@http://localhost:8080/TestSimpleType/org.yournamehere.Main.nocache.js:11 at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:195) at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:120) at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:507) at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:284) at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107) at com.smartgwt.client.data.SimpleType.setNormalDisplayFormatter(SimpleType.java) at org.yournamehere.client.MainEntryPoint.onModuleLoad(MainEntryPoint.java:22) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.ModuleSpace.onLoad(ModuleSpace.java:369) at com.google.gwt.dev.shell.OophmSessionHandler.loadModule(OophmSessionHandler.java:185) at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:380) at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:222) at java.lang.Thread.run(Thread.java:619)
MichalG
SmartGWT svn 1141, GWT2