wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Grigorov <mgrigo...@apache.org>
Subject Re: "ChangeListener" for the RadioGroup Component
Date Fri, 15 Jun 2012 08:30:30 GMT
Something like:

final Label label = ...
RadioChoice<String> sites = new RadioChoice<String>("site", SITES);
		sites.add(new AjaxFormChoiceComponentUpdatingBehavior()
		{
			@Override
			protected void onUpdate(AjaxRequestTarget target)
			{

label.setDefaultModelObject(sites.getModelObject());
				target.add(label);
			}
		});

On Fri, Jun 15, 2012 at 11:25 AM, Dmitriy Neretin
<dmitriy.neretin@googlemail.com> wrote:
> Thanks!
>
> Can you describe how can I use the AjaxFormChoiceComponentUpdatingBehavior()
> with the label?
>
> 2012/6/15 Martin Grigorov <mgrigorov@apache.org>
>
>> Hi,
>>
>> #onSelectionChanged() works only if you override
>> #wantOnSelectionChanged() to return true.
>> Otherwise you can also use AjaxFormChoiceComponentUpdatingBehavior()
>> and update the label with Ajax.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com

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


Mime
View raw message