Hi Gabriel,

thanks for your help.

Regards
Marco

Il 27/08/2015 20:27, Gabriel Landon ha scritto:
You mean something like this :

public class PanelContentModal extends Modal<Void> {
     /** close callback. */
     private WindowClosedCallback windowClosedCallback = null;


     public PanelContentModal(final String varMarkupId) {
         super(varMarkupId);
         setUseCloseHandler(true);
     }

     @Override
     protected void onClose(final AjaxRequestTarget paramTarget) {
         if (windowClosedCallback != null) {
             windowClosedCallback.onClose(paramTarget);
         }
     }

      public PanelContentModal setWindowClosedCallback(final
WindowClosedCallback callback) {
         windowClosedCallback = callback;
         return this;
     }
}

And then use it like a ModalWindow :

PanelContentModal  modal = new PanelContentModal("yourId");
modal.setWindowClosedCallback(new WindowClosedCallback() {
     @Override
     public void onClose(final AjaxRequestTarget paramTarget) {
         // Do your refresh
     }
});

regards,

Gabriel.
});

--
View this message in context: 
http://apache-wicket.1842946.n4.nabble.com/Modal-closed-callback-tp4671861p4671862.html
Sent from the Users forum mailing list archive at Nabble.com.

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


--
Dott. Marco Di Sabatino Di Diodoro
Tel. +39 3939065570

Tirasa S.r.l.
Viale D'Annunzio 267 - 65127 Pescara
Tel +39 0859116307 / FAX +39 0859111173
http://www.tirasa.net

Apache Syncope PMC Member
http://people.apache.org/~mdisabatino/

Reply via email to