conversion is done by components not by models. you can override the converter on your component.
-igor On Thu, Sep 16, 2010 at 9:38 AM, Baschir Jaghoori <baschir.jagho...@mgm-tp.com> wrote: > Hi, > > I want to output the width and height fields of a java.awt.Dimension > object (which are integers) and tried to use the PropertyModel, but > because PropertyModel calls getWidth() / getHeight() (which return > doubles), the result is displayed as 100.0 instead of 100 > > It seems, that there was a constructor in PropertyModel for this case, > but it seems to have disappeared - wonder why? And is there any other > "nice" way to convert the double to int - other than to implement my own > model? > > PropertyModel(java.lang.Object modelObject, java.lang.String expression, > java.lang.Class propertyType) > > Cheers, > Baschir > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org