From 41d412d3b5e6d0a27b82b732372934ec79d7d575 Mon Sep 17 00:00:00 2001 From: sk89q Date: Thu, 9 Jan 2014 09:43:42 -0800 Subject: [PATCH] Added "Launcher console" button to config dialog. --- .../com/skcraft/launcher/dialog/ConfigurationDialog.java | 9 +++++++++ .../com/skcraft/launcher/lang/Launcher.properties | 1 + 2 files changed, 10 insertions(+) diff --git a/src/main/java/com/skcraft/launcher/dialog/ConfigurationDialog.java b/src/main/java/com/skcraft/launcher/dialog/ConfigurationDialog.java index ae7fffa..a08b05e 100644 --- a/src/main/java/com/skcraft/launcher/dialog/ConfigurationDialog.java +++ b/src/main/java/com/skcraft/launcher/dialog/ConfigurationDialog.java @@ -49,6 +49,7 @@ public class ConfigurationDialog extends JDialog { private final LinedBoxPanel buttonsPanel = new LinedBoxPanel(true); private final JButton okButton = new JButton(_("button.ok")); private final JButton cancelButton = new JButton(_("button.cancel")); + private final JButton logButton = new JButton(_("options.launcherConsole")); /** * Create a new configuration dialog. @@ -114,6 +115,7 @@ public class ConfigurationDialog extends JDialog { SwingHelper.removeOpaqueness(advancedPanel); tabbedPane.addTab(_("options.advancedTab"), SwingHelper.alignTabbedPane(advancedPanel)); + buttonsPanel.addElement(logButton); buttonsPanel.addGlue(); buttonsPanel.addElement(okButton); buttonsPanel.addElement(cancelButton); @@ -133,6 +135,13 @@ public class ConfigurationDialog extends JDialog { save(); } }); + + logButton.addActionListener(new ActionListener() { + @Override + public void actionPerformed(ActionEvent e) { + ConsoleFrame.showMessages(); + } + }); } /** diff --git a/src/main/resources/com/skcraft/launcher/lang/Launcher.properties b/src/main/resources/com/skcraft/launcher/lang/Launcher.properties index 624ab64..4ce0bf3 100644 --- a/src/main/resources/com/skcraft/launcher/lang/Launcher.properties +++ b/src/main/resources/com/skcraft/launcher/lang/Launcher.properties @@ -42,6 +42,7 @@ options.proxyPassword=Proxy password\: options.proxyTab=Proxy options.gameKey=Game key\: options.advancedTab=Advanced +options.launcherConsole=Launcher console instance.openFolder=Open folder instance.openSaves=Open saves folder