Thanks. A broader fix for this and most other types has been on the verge of being committed for something like a week now. Stay tuned.
On Wed, Jul 28, 2010 at 2:10 PM, <[email protected]> wrote: > Reviewers: , > > Description: > If you create a Record that needs to transfer a Boolean type, it fails. > Here is the patch to fix it. > > Please review this at http://gwt-code-reviews.appspot.com/703802/show > > Affected files: > user/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java > > > Index: user/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java > =================================================================== > --- user/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java > (revision 8401) > +++ user/src/com/google/gwt/valuestore/shared/impl/RecordJsoImpl.java > (working copy) > @@ -81,6 +81,9 @@ > // "Cannot ask for a property before setting it: " > // + property.getName(); > > + if (Boolean.class.equals(property.getType())) { > + return (V) Boolean.valueOf(getBoolean(property.getName())); > + } > if (Integer.class.equals(property.getType())) { > return (V) Integer.valueOf(getInt(property.getName())); > } > @@ -238,6 +241,10 @@ > return @java.util.Date::createFrom(D)(millis); > }-*/;; > > + private native boolean getBoolean(String name) /*-{ > + return this[name]; > + }-*/; > + > private native double getDouble(String name) /*-{ > return this[name]; > }-*/; > > > -- > http://groups.google.com/group/Google-Web-Toolkit-Contributors > -- http://groups.google.com/group/Google-Web-Toolkit-Contributors
