Re: add javascript after AjaxLazyLoadPanel finishes rendering - (was: onAfterRender called twice in AjaxLazyLoadPanel)

2010-01-21 Thread Steve Swinsburg
-called-twice-in-AjaxLazyLoadPanel-tp27252299p27253924.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h

Re: add javascript after AjaxLazyLoadPanel finishes rendering - (was: onAfterRender called twice in AjaxLazyLoadPanel)

2010-01-21 Thread Steve Swinsburg
- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- View this message in context: http://old.nabble.com/onAfterRender-called-twice-in-AjaxLazyLoadPanel-tp27252299p27253924.html Sent from the Wicket - User

onAfterRender called twice in AjaxLazyLoadPanel

2010-01-20 Thread Steve Swinsburg
I have an AjaxLazyLoadPanel and want some javascript to fire after its loaded it's contents: I assumed I could override onAfterRender and add my javascript like so: add(new AjaxLazyLoadPanel(myPanel) { @Override public Component getLazyLoadComponent(String markupId) {

Re: onAfterRender called twice in AjaxLazyLoadPanel

2010-01-20 Thread Igor Vaynberg
you are writing out javascript after every component render... perhaps you should keep a boolean flag that marks if you rendered the js yet or not. alternatively you can add a behavior to the panel with istemporary() { return true; } -igor On Wed, Jan 20, 2010 at 7:24 PM, Steve Swinsburg

Re: onAfterRender called twice in AjaxLazyLoadPanel

2010-01-20 Thread Steve Swinsburg
So overriding onAfterRender for a component doesn't just override it for that instance of the component? Also I can see the markup is being added to the end of the page after the closing HTML. However, the Javadocs say it is meant to be called after after the actual component is finished

Re: onAfterRender called twice in AjaxLazyLoadPanel

2010-01-20 Thread Lionel Port
Hi Steve, Are you trying to do this.. http://cwiki.apache.org/WICKET/adding-javascript-from-wicket.html with an onload event instead of onblur, or do I misunderstand. regards, Lionel On Thu, Jan 21, 2010 at 2:56 PM, Steve Swinsburg steve.swinsb...@gmail.com wrote: So  overriding