我看你还是使用dialog吧
关闭操作无发屏蔽
但是你可以重载方法,让关闭不做任何事情
protected void processWindowEvent(WindowEvent e) {
super.processWindowEvent(e);
if (e.getID() == WindowEvent.WINDOW_CLOSING) {
//System.exit(0);本来应该退出的,你这里注释掉
}
}
关闭操作无发屏蔽
但是你可以重载方法,让关闭不做任何事情
protected void processWindowEvent(WindowEvent e) {
super.processWindowEvent(e);
if (e.getID() == WindowEvent.WINDOW_CLOSING) {
//System.exit(0);本来应该退出的,你这里注释掉
}
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货