Hi Everyone,

ModalWindow has a "setPageCreator()" method, to set the page that you want
to display inside of the ModalWindow.

I've never used Wicket's event infrastructure, but I decided to use it today
to pass a message from the content of my ModalWindow back to the ModalWindow
itself.

Apparently, even if you use an event sink at the session or application
level, the event only broadcasts to components of the page that the event
originated from... A lot of Google searching took me to a post on the
mailing list that described that behavior, and let me to the below workaround.

I ended up using getSession().getPageManager().getPage(int id...) on my
content page to retrieve the page that contained the modal window.  Using
that as the event sink (instead of getSession() or Application.get()),
allowed the ModalWindow to consume my event...

Is it at all possible for one of the following "enhancements" to be made:

1) When inside of a ModalWindow, getPage().getParent() returns null.  Is
there a reason for this?  It would be *awesome* if getPage().getParent()
could return the ModalWindow that created the page.

2) I guess if 1) occurred, then events would properly propagate to the
ModalWindow when using a session or application level sink.

Thanks for your feedback.

Regards,
Aaron J. Garcia


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

Reply via email to