From 7fee3aa0055f2ac28ca5676d575eccde5190bfe3 Mon Sep 17 00:00:00 2001 From: yugecin Date: Thu, 12 Jan 2017 11:31:58 +0100 Subject: [PATCH] remove exit code from errorhandler --- src/yugecin/opsudance/OpsuDance.java | 3 ++- src/yugecin/opsudance/errorhandling/ErrorHandler.java | 5 ----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/yugecin/opsudance/OpsuDance.java b/src/yugecin/opsudance/OpsuDance.java index 1022158f..369ba2e9 100644 --- a/src/yugecin/opsudance/OpsuDance.java +++ b/src/yugecin/opsudance/OpsuDance.java @@ -44,7 +44,8 @@ public class OpsuDance { try { container.setup(); } catch (LWJGLException e) { - ErrorHandler.error("could not initialize GL", e, container).showAndExit(); + ErrorHandler.error("could not initialize GL", e, container).preventContinue().show(); + System.exit(1); } Exception caughtException = null; try { diff --git a/src/yugecin/opsudance/errorhandling/ErrorHandler.java b/src/yugecin/opsudance/errorhandling/ErrorHandler.java index 6b396c19..411afa0c 100644 --- a/src/yugecin/opsudance/errorhandling/ErrorHandler.java +++ b/src/yugecin/opsudance/errorhandling/ErrorHandler.java @@ -229,9 +229,4 @@ public class ErrorHandler { return ignoreAndContinue; } - public void showAndExit() { - show(); - System.exit(1); - } - }