You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Ed _ <ed...@hotmail.com> on 2009/12/05 00:09:22 UTC

Closing ModalWindows on page with multiple modal windows

Hi,

I have a page with several panels each of them them have links that open modal windows. Essentially there are a number of modal windows on the page most are hidden.  They all open up and I am able to close them with the Cross (X) link. 


In one of the modal windows the content has an ajaxLink that closes the modal window.


AjaxLink cancelSyncLink = new AjaxLink("CloseWindowLink") {
            @Override
            public void onClick(AjaxRequestTarget target) {
            
                log.info("CloseWindowLink called");
                modalWindow.closeCurrent(target);
               // modalWindow.close(target);
            }
        };


The function gets called but the modal window does not close. 

I have tried both closeCurrent and close calls.


The same works on a page that has only one ModalWindow. 


Any ideas how I can fix this. 


thanks!
 		 	   		  
_________________________________________________________________
Windows Live Hotmail gives you a free,exclusive  gift.
http://www.microsoft.com/windows/windowslive/hotmail_bl1/hotmail_bl1.aspx?ocid=PID23879::T:WLMTAGL:ON:WL:en-ww:WM_IMHM_7:092009

RE: Closing ModalWindows on page with multiple modal windows

Posted by Ed _ <ed...@hotmail.com>.
And the application is  throwing an exception. On repeated tries to close the ModalWindow via the AjaxLink

[2009-12-04 16:45:34,942]ERROR [http-8080-4] (RequestCycle.java:1521) - org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap modal-dialog-pagemap is still locked by: Thread[http-8080-6,5,main], giving up trying to get the page for path: 2:CloseWindowLink
    Begin of stack trace of Thread[http-8080-6,5,main]
    java.lang.Object.wait(Native Method)
    java.lang.Object.wait(Object.java:474)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.await(JIoEndpoint.java:416)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:442)
    java.lang.Thread.run(Thread.java:613)
    End of stack trace of Thread[http-8080-6,5,main]
org.apache.wicket.protocol.http.request.InvalidUrlException: org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap modal-dialog-pagemap is still locked by: Thread[http-8080-6,5,main], giving up trying to get the page for path: 2:CloseWindowLink
    Begin of stack trace of Thread[http-8080-6,5,main]
    java.lang.Object.wait(Native Method)
    java.lang.Object.wait(Object.java:474)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.await(JIoEndpoint.java:416)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:442)
    java.lang.Thread.run(Thread.java:613)
    End of stack trace of Thread[http-8080-6,5,main]
    at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:262)
    at org.apache.wicket.RequestCycle.step(RequestCycle.java:1310)
    at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1428)
    at org.apache.wicket.RequestCycle.request(RequestCycle.java:545)
    at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:468)
    at org.apache.wicket.protocol.http.WicketServlet.doGet(WicketServlet.java:138)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
    at java.lang.Thread.run(Thread.java:613)
Caused by: org.apache.wicket.WicketRuntimeException: After 1 minute the Pagemap modal-dialog-pagemap is still locked by: Thread[http-8080-6,5,main], giving up trying to get the page for path: 2:CloseWindowLink
    Begin of stack trace of Thread[http-8080-6,5,main]
    java.lang.Object.wait(Native Method)
    java.lang.Object.wait(Object.java:474)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.await(JIoEndpoint.java:416)
    org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:442)
    java.lang.Thread.run(Thread.java:613)
    End of stack trace of Thread[http-8080-6,5,main]
    at org.apache.wicket.Session.getPage(Session.java:769)
    at org.apache.wicket.request.AbstractRequestCycleProcessor.resolveRenderedPage(AbstractRequestCycleProcessor.java:458)
    at org.apache.wicket.protocol.http.WebRequestCycleProcessor.resolve(WebRequestCycleProcessor.java:144)
    ... 20 more


> From: ed_b_71@hotmail.com
> To: users@wicket.apache.org
> Subject: RE: Closing ModalWindows on page with multiple modal windows
> Date: Fri, 4 Dec 2009 15:21:36 -0800
> 
> 
> Using version 1.4.3
> 
> Would really ppreciate suggestions.
> 
> > From: ed_b_71@hotmail.com
> > To: users@wicket.apache.org
> > Subject: Closing ModalWindows on page with multiple modal windows
> > Date: Fri, 4 Dec 2009 15:09:22 -0800
> > 
> > 
> > Hi,
> > 
> > I have a page with several panels each of them them have links that open modal windows. Essentially there are a number of modal windows on the page most are hidden.  They all open up and I am able to close them with the Cross (X) link. 
> > 
> > 
> > In one of the modal windows the content has an ajaxLink that closes the modal window.
> > 
> > 
> > AjaxLink cancelSyncLink = new AjaxLink("CloseWindowLink") {
> >             @Override
> >             public void onClick(AjaxRequestTarget target) {
> >             
> >                 log.info("CloseWindowLink called");
> >                 modalWindow.closeCurrent(target);
> >                // modalWindow.close(target);
> >             }
> >         };
> > 
> > 
> > The function gets called but the modal window does not close. 
> > 
> > I have tried both closeCurrent and close calls.
> > 
> > 
> > The same works on a page that has only one ModalWindow. 
> > 
> > 
> > Any ideas how I can fix this. 
> > 
> > 
> > thanks!
> >  		 	   		  
> > _________________________________________________________________
> > Windows Live Hotmail gives you a free,exclusive  gift.
> > http://www.microsoft.com/windows/windowslive/hotmail_bl1/hotmail_bl1.aspx?ocid=PID23879::T:WLMTAGL:ON:WL:en-ww:WM_IMHM_7:092009
>  		 	   		  
> _________________________________________________________________
> Windows 7: Unclutter your desktop. Learn more.
> http://www.microsoft.com/windows/windows-7/videos-tours.aspx?h=7sec&slideid=1&media=aero-shake-7second&listid=1&stop=1&ocid=PID24727::T:WLMTAGL:ON:WL:en-US:WWL_WIN_7secdemo:122009
 		 	   		  
_________________________________________________________________
Windows Live Hotmail gives you a free,exclusive  gift.
http://www.microsoft.com/windows/windowslive/hotmail_bl1/hotmail_bl1.aspx?ocid=PID23879::T:WLMTAGL:ON:WL:en-ww:WM_IMHM_7:092009

RE: Closing ModalWindows on page with multiple modal windows

Posted by Ed _ <ed...@hotmail.com>.
Using version 1.4.3

Would really ppreciate suggestions.

> From: ed_b_71@hotmail.com
> To: users@wicket.apache.org
> Subject: Closing ModalWindows on page with multiple modal windows
> Date: Fri, 4 Dec 2009 15:09:22 -0800
> 
> 
> Hi,
> 
> I have a page with several panels each of them them have links that open modal windows. Essentially there are a number of modal windows on the page most are hidden.  They all open up and I am able to close them with the Cross (X) link. 
> 
> 
> In one of the modal windows the content has an ajaxLink that closes the modal window.
> 
> 
> AjaxLink cancelSyncLink = new AjaxLink("CloseWindowLink") {
>             @Override
>             public void onClick(AjaxRequestTarget target) {
>             
>                 log.info("CloseWindowLink called");
>                 modalWindow.closeCurrent(target);
>                // modalWindow.close(target);
>             }
>         };
> 
> 
> The function gets called but the modal window does not close. 
> 
> I have tried both closeCurrent and close calls.
> 
> 
> The same works on a page that has only one ModalWindow. 
> 
> 
> Any ideas how I can fix this. 
> 
> 
> thanks!
>  		 	   		  
> _________________________________________________________________
> Windows Live Hotmail gives you a free,exclusive  gift.
> http://www.microsoft.com/windows/windowslive/hotmail_bl1/hotmail_bl1.aspx?ocid=PID23879::T:WLMTAGL:ON:WL:en-ww:WM_IMHM_7:092009
 		 	   		  
_________________________________________________________________
Windows 7: Unclutter your desktop. Learn more.
http://www.microsoft.com/windows/windows-7/videos-tours.aspx?h=7sec&slideid=1&media=aero-shake-7second&listid=1&stop=1&ocid=PID24727::T:WLMTAGL:ON:WL:en-US:WWL_WIN_7secdemo:122009