-
Bug
-
Resolution: Fixed
-
Normal
-
7.0.4
-
None
-
None
If we remove Clients.confirmClose("Make sure"), it will work.
Right behavior is using Clients.confirmClose shouldn't affect DesktopCleanup.
// composer
Bar.java
import org.zkoss.zk.ui.Executions; import org.zkoss.zk.ui.select.SelectorComposer; import org.zkoss.zk.ui.util.Clients; import org.zkoss.zk.ui.util.DesktopCleanup; import org.zkoss.zul.Window; public class Composer849 extends SelectorComposer<Window> { private static final long serialVersionUID = -7360829196117880724L; @Override public void doAfterCompose(Window comp) throws Exception { Clients.confirmClose("Make sure"); Executions.getCurrent().getDesktop().addListener(new DesktopCleanup(){ @Override public void cleanup(org.zkoss.zk.ui.Desktop desktop) throws Exception { System.out.println("test..."); } }); super.doAfterCompose(comp); } }
// zul
<zk> <zk> <window border="normal" title="hello" apply="Composer849"> <div>Welcome to ZK Fiddle , run it right now!</div> </window> <script> </script> </zk> </zk>
- is duplicated by
-
ZK-2505 page with confirmClose don't rise rmDesktop event
- Closed