Am 22.06.2011 06:54, schrieb Hans Lesmeister 2:
FeanorsCurse wrote:
However, I still feel like that is an unnecessary step; I don't see any
reason why the PropertyModel should not be enough on its own.

Please correct me if I am wrong: The model passed in tells the dropdown
which object from the list should be the active one shown. If you don't
apply a renderer then some default is used to render the options and that is
obviously toString() on each object in the list. Ergo: The result object
from evaluating the model should be the same type as the objects in the
list.

-----
Correct. But if you don't use a renderer they have to be the same instance to. Otherwise equals used by list is not recognizing "same object". The renderer takes that part with the String getIdValue(T object, int index); method. Here you can implement the equals
logic.

Cheers
Mike

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to