y, February 19, 2006 12:33 AM
> To: wicket-user@lists.sourceforge.net
> Subject: Re: [Wicket-user] New RequiredValidator and DropDownChoice
>
> Ok, I think this is the right fix (it's in HEAD now):
>
> public final void onValidate(final FormComponent
the changes that where made where wrong anyway.I think this will handle most situations.. (especially components not disabled in wicket but only in html, which could be pretty common)johan
On 2/19/06, Eelco Hillenius <[EMAIL PROTECTED]> wrote:
Do the other devs agree with the fix? I especially woul
Do the other devs agree with the fix? I especially would like opinions
about enabled.
Eelco
---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
se
I play with new fix and all of my use cases passed ! Great !Thanks a lot.On 2/19/06, Eelco Hillenius <
[EMAIL PROTECTED]> wrote:Ok, I think this is the right fix (it's in HEAD now):
public final void onValidate(final FormComponent formComponent, finalString value){//
Ok, I think this is the right fix (it's in HEAD now):
public final void onValidate(final FormComponent formComponent, final
String value)
{
// Check value only if form component is enabled
if (!formComponent.isEnabled())
{
Uh, another potential nastier problem is that you put in
disabled="disabled" there yourself either directly or with an
attribute modifier. In that case, the old code makes sense, though it
is not very generic. H... what should we do...
Eelco
On 2/18/06, Eelco Hillenius <[EMAIL PROTECTED]> wro
A potential, theoretic issue can be that isEnabled is based on an
algoritm in such a way that it was false during rendering, but true
now that the post back comes in. Or the other way around. But I think
that is too theoretical to worry about, and even if it would show up
sometime, somewhere for an
I just took a look, and the 'fix' that isInputNullable was wrong; it
was fixing the wrong problem in the first place. I removed that method
again, and RequiredValidator now looks like:
public final void onValidate(final FormComponent formComponent, final
String value)
{
Latest RequiredValidator only works for FormComponent.isInputNullable() that return true.So basically RequiredValidator no longer work for FormComponent like DropDownChoice .
I have one use case: the choices List may return zero size, and by
default, DropDownChoice will insert a Choose One... for