summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/com/dabomstew/pkrandom/newgui/Bundle.properties3
-rw-r--r--src/com/dabomstew/pkrandom/newgui/NewRandomizerGUI.java43
2 files changed, 0 insertions, 46 deletions
diff --git a/src/com/dabomstew/pkrandom/newgui/Bundle.properties b/src/com/dabomstew/pkrandom/newgui/Bundle.properties
index 7fc4e29..b324c05 100644
--- a/src/com/dabomstew/pkrandom/newgui/Bundle.properties
+++ b/src/com/dabomstew/pkrandom/newgui/Bundle.properties
@@ -393,9 +393,6 @@ GUI.settingsLoadFailed=Settings file load failed. Please try again.
GUI.settingsSaveFailed=Settings file save failed. Please try again.
GUI.cantLoadCustomNames=Could not initialise custom names data.\nPlease redownload the randomizer and try again.
GUI.customNamesEditorMenuItem.text=Custom Names Editor
-GUI.updateOldSettingsMenuItem.text=Update Pre-3.0.0 Settings File
-GUI.oldSettingsFileUpdated=Settings file has been updated.
-GUI.oldSettingsFileInvalid=Provided settings file is not pre-3.0.0 (or otherwise invalid).
GUI.mtMovesPanel.toolTipText=
GUI.mtMovesPanel.text=
GUI.mtCompatPanel.toolTipText=
diff --git a/src/com/dabomstew/pkrandom/newgui/NewRandomizerGUI.java b/src/com/dabomstew/pkrandom/newgui/NewRandomizerGUI.java
index f89292d..c9d8506 100644
--- a/src/com/dabomstew/pkrandom/newgui/NewRandomizerGUI.java
+++ b/src/com/dabomstew/pkrandom/newgui/NewRandomizerGUI.java
@@ -307,7 +307,6 @@ public class NewRandomizerGUI {
private JPopupMenu settingsMenu;
private JMenuItem customNamesEditorMenuItem;
- private JMenuItem updateOldSettingsMenuItem;
private JMenuItem applyGameUpdateMenuItem;
private JMenuItem removeGameUpdateMenuItem;
private JMenuItem loadGetSettingsMenuItem;
@@ -469,7 +468,6 @@ public class NewRandomizerGUI {
loadSettingsButton.addActionListener(e -> loadQS());
saveSettingsButton.addActionListener(e -> saveQS());
settingsButton.addActionListener(e -> settingsMenu.show(settingsButton,0,settingsButton.getHeight()));
- updateOldSettingsMenuItem.addActionListener(e -> updateOldSettingsMenuItemActionPerformed());
customNamesEditorMenuItem.addActionListener(e -> new CustomNamesEditorDialog(frame));
applyGameUpdateMenuItem.addActionListener(e -> applyGameUpdateMenuItemActionPerformed());
removeGameUpdateMenuItem.addActionListener(e -> removeGameUpdateMenuItemActionPerformed());
@@ -622,10 +620,6 @@ public class NewRandomizerGUI {
customNamesEditorMenuItem.setText(bundle.getString("GUI.customNamesEditorMenuItem.text"));
settingsMenu.add(customNamesEditorMenuItem);
- updateOldSettingsMenuItem = new JMenuItem();
- updateOldSettingsMenuItem.setText(bundle.getString("GUI.updateOldSettingsMenuItem.text"));
- settingsMenu.add(updateOldSettingsMenuItem);
-
loadGetSettingsMenuItem = new JMenuItem();
loadGetSettingsMenuItem.setText(bundle.getString("GUI.loadGetSettingsMenuItem.text"));
settingsMenu.add(loadGetSettingsMenuItem);
@@ -1077,43 +1071,6 @@ public class NewRandomizerGUI {
return saveType;
}
- private void updateOldSettingsMenuItemActionPerformed() {
-
- qsUpdateChooser.setSelectedFile(null);
- int returnVal = qsUpdateChooser.showOpenDialog(frame);
- if (returnVal == JFileChooser.APPROVE_OPTION) {
- File fh = qsUpdateChooser.getSelectedFile();
- try {
- FileInputStream in = new FileInputStream(fh);
- int version = in.read();
- if (version == 0 || version > 172) {
- JOptionPane.showMessageDialog(frame, bundle.getString("GUI.oldSettingsFileInvalid"));
- in.close();
- return;
- }
- int length = in.read();
- byte[] buffer = FileFunctions.readFullyIntoBuffer(in, length);
- in.close();
-
- ByteBuffer buf = ByteBuffer.allocate(length + 8);
- buf.putInt(version);
- buf.putInt(length);
- buf.put(buffer);
-
- FileOutputStream out = new FileOutputStream(fh);
- out.write(buf.array());
- out.close();
- JOptionPane.showMessageDialog(frame, bundle.getString("GUI.oldSettingsFileUpdated"));
- } catch (IllegalArgumentException ex) {
- ex.printStackTrace();
- JOptionPane.showMessageDialog(frame, bundle.getString("GUI.invalidSettingsFile"));
- } catch (IOException ex) {
- ex.printStackTrace();
- JOptionPane.showMessageDialog(frame, bundle.getString("GUI.settingsLoadFailed"));
- }
- }
- }
-
private void applyGameUpdateMenuItemActionPerformed() {
if (romHandler == null) return;