Closing the window now does the same as Quit

ui:
* Add a WindowListener catching the event of closing the window to ask
  the user if the maze must be saved or not (if it's not already saved)
  (same behavior as the Quit button) (see #19)
This commit is contained in:
regar42 committed 2017-12-26 16:45:47 +01:00
1 parent 9b272e5f25
commit 8bef42e2a6
2 files changed
+39 -3

No files matched your search

+1 -1
View File
@@ -12,7 +12,7 @@ public class SaveBox {
MazeApp mazeApp,
String title) {
MazeAppModel mazeAppModel = mazeApp.getMazeAppModel();
int response = JOptionPane.showInternalOptionDialog(parent,
int response = JOptionPane.showOptionDialog(parent,
message,
title,
JOptionPane.YES_NO_CANCEL_OPTION,