This topic has been archived. It cannot be replied.
-
工作学习 / 专业技术讨论 / Learning SWING,write a simple code to test event mode,why can not exit from system menu,please help!,button is working
-xiangdang(大魏);
2006-8-6
{685}
(#3127367@0)
-
Swing中的event listener-WindowAdapter 中的windowClosed(WindowEvent) 和windowClosing(WindowEvent)有什么区别?高手指点一下,多谢了!!
-xiangdang(大魏);
2006-8-8
(#3129328@0)
-
you may have already had the answer, add this method inside your addWindowListener:
public void windowClosing(WindowEvent e){ dispose(); }Frame inherits the dispose method from its Window superclass. When called, dispose destroys all native resources (including memory) associated with a component object, and, a call to dispose results in a call to a registered WindowListener's windowClosed method.
-zyxwvu(Its2warm);
2006-8-8
{263}
(#3129525@0)