Can you just override isTemporary()?

On Sat, Oct 11, 2008 at 8:34 AM, Artur W. <[EMAIL PROTECTED]> wrote:
>
> Hi!
>
> I added simple simple behavior:
>
> public class XDateField extends DateTextField {
>
>    public XDateField(String id, IModel model) {
>        super(id, model, "yyyy-MM-dd");
>
>        add(new AbstractBehavior() {
>            @Override
>            public void onRendered(Component component) {
>                Response response = component.getResponse();
>                response.write("\n&lt;a href=\"#\" onclick=\"changeDate('" +
> component.getMarkupId() + "', -1)\"&gt;(DEC)&lt;/a&gt;");
>            }
>        });
>        add(new DatePicker());
>    }
> }
>
> It is rendering ok. But when the component is re-rendered via ajax
> (target.addComponent(dateTextField))
> my behavior is re-added. After each re-render my link looks like this:
> [component] (DEC)(DEC)(DEC)(DEC)... [calendarIcon]
>
>
> How to fix it?
>
> Thanks in advance,
> Artur
>
>
> --
> View this message in context: 
> http://www.nabble.com/AbstractBehavior-problem-after-comonent-re-render-tp19932224p19932224.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to