mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 03:38:01 +00:00
Always prompt user before exiting or restarting Forge
This commit is contained in:
@@ -136,11 +136,12 @@ public enum FControl implements KeyEventDispatcher {
|
||||
}
|
||||
|
||||
public boolean canExitForge(boolean forRestart) {
|
||||
String userPrompt = "Are you sure you wish to " + (forRestart ? "restart" : "exit") + " Forge?";
|
||||
if (this.game != null) {
|
||||
String userPrompt = "A game is currently active. Are you sure you wish to " + (forRestart ? "restart" : "exit") + " Forge?\n\n";
|
||||
if (!MenuUtil.getUserConfirmation(userPrompt, "Exit Forge")) {
|
||||
return false;
|
||||
}
|
||||
userPrompt = "A game is currently active. " + userPrompt;
|
||||
}
|
||||
if (!MenuUtil.getUserConfirmation(userPrompt, "Exit Forge")) {
|
||||
return false;
|
||||
}
|
||||
if (!CDeckEditorUI.SINGLETON_INSTANCE.canExit()) {
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user