From 8175064600bdf3bc775c84cfa5ce93548fa879e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9da=20Housni=20Alaoui?= Date: Thu, 9 Jun 2016 00:51:05 +0200 Subject: [PATCH] #57 Let the user close the getdown window on error, even when hideDecorations is set to true --- .../com/threerings/getdown/launcher/GetdownApp.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/main/java/com/threerings/getdown/launcher/GetdownApp.java b/src/main/java/com/threerings/getdown/launcher/GetdownApp.java index 06c8e5a..dc6b06a 100644 --- a/src/main/java/com/threerings/getdown/launcher/GetdownApp.java +++ b/src/main/java/com/threerings/getdown/launcher/GetdownApp.java @@ -184,6 +184,19 @@ public class GetdownApp System.exit(exitCode); } } + + @Override + protected void fail(String message) { + // If the frame was set to be undecorated, make window decoration available + // to allow the user to close the window + if(_frame != null && _frame.isUndecorated()){ + _frame.dispose(); + _frame.setUndecorated(false); + showContainer(); + } + super.fail(message); + } + protected JFrame _frame; }; app.start();