It depends what you want to achieve.
For simple things just use IndicatingAjaxButton/Link from
wicket-extensions.

On Fri, 2008-05-02 at 13:09 +0000, i ii wrote:
> much work for simple feature, no?
> 
> > Date: Fri, 2 May 2008 15:46:04 +0300
> > From: [EMAIL PROTECTED]
> > To: [email protected]
> > Subject: Re: ajax progress indicator
> > 
> > I haven't found much. Here are some snipplets that may be of use:
> > 
> > public class AjaxIndicatorContainer extends WebMarkupContainer {
> >   /**
> >    * Constructor for TODO
> >    * @param form
> >    */
> >   public AjaxIndicatorContainer(Form form) {
> >     super("ajaxIndicator"); // wicket:id
> >     setOutputMarkupId(true);
> >     setMarkupId("ajaxIndicatorId"); // markup:id
> >     form.add(this);
> >   }
> > 
> >   /**
> >    * @see 
> > org.apache.wicket.Component#onComponentTag(org.apache.wicket.markup.ComponentTag)
> >    */
> >   @Override
> >   protected void onComponentTag(ComponentTag tag) {
> >     super.onComponentTag(tag);
> >     tag.put("src",urlFor(AbstractDefaultAjaxBehavior.INDICATOR));
> >   }
> > }
> > 
> > 
> >     final AjaxIndicatorContainer indicatorContainer = new
> > AjaxIndicatorContainer(loginForm);
> > 
> > {
> >       final AjaxButton loginButton = new
> > AbstractAjaxIndicatorAwareButton(LOGIN_BUTTON, loginForm) {
> > 
> >         /**
> >          * @see
> > org.apache.wicket.ajax.markup.html.form.AjaxButton#onSubmit(org.apache.wicket.ajax.AjaxRequestTarget,
> > org.apache.wicket.markup.html.form.Form)
> >          */
> >         @Override
> >         protected void onSubmit(AjaxRequestTarget target, Form form) {
> >           processLogin(userIdField, passwdField);
> >           target.addComponent(feedbackPanel); // Update feedback panel too
> >         }
> > 
> >         public String getAjaxIndicatorMarkupId() {
> >           return indicatorContainer.getMarkupId();
> >         }
> >       };
> >       loginForm.add(loginButton);
> >     }
> > 
> > 2008/5/2 i ii <[EMAIL PROTECTED]>:
> > >
> > >  is documentation available for ajax progess indicator. i cannot find :(
> > >
> > 
> > ---------------------------------------------------------------------
> > 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