下面列出了java.awt.desktop.QuitEvent#java.awt.desktop.QuitResponse 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。
@Override
public void handleQuitRequestWith(QuitEvent event, QuitResponse response) {
if (!UIUtilities.inModalState()) {
mAllowQuitIfNoSignificantWindowsOpen = false;
if (closeFrames(true)) {
if (closeFrames(false)) {
saveState();
response.performQuit();
return;
}
}
mAllowQuitIfNoSignificantWindowsOpen = true;
}
response.cancelQuit();
}
@Override
public void handleQuitRequestWith(QuitEvent e, QuitResponse response) {
handleQuit();
//need to do this otherwise the user will never be able to quit again
response.cancelQuit();
}
@Override
public void handleQuitRequestWith(final QuitEvent quitEvent, final QuitResponse quitResponse)
{
PCGenUIManager.closePCGen();
}
@Override
public void handleQuitRequestWith(final QuitEvent quitEvent, final QuitResponse quitResponse)
{
PCGenUIManager.closePCGen();
}