setTitle("Stuckless Mod Manager - " + Version.VERSION);
setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
setBounds(100, 100, 603, 402);
JMenuBar menuBar = new JMenuBar();
setJMenuBar(menuBar);
JMenu mnFile = new JMenu("File");
menuBar.add(mnFile);
JMenuItem mntmAddMod = new JMenuItem("Add Mods...");
mntmAddMod.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
addModAction();
}
});
mntmAddMod.setIcon(Application.icon("list-add"));
mnFile.add(mntmAddMod);
JMenuItem mntmExit = new JMenuItem("Exit");
mntmExit.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
exit();
}
});
mntmExit.setIcon(Application.icon("system-log-out"));
JMenuItem mntmClearMods = new JMenuItem("Clear Mods");
mntmClearMods.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
((DefaultTableModel) table.getModel()).getDataVector().clear();
table.repaint();
}
});
mntmClearMods.setIcon(Application.icon("list-remove"));
mnFile.add(mntmClearMods);
JMenuItem mntmPreferences = new JMenuItem("Preferences");
mnFile.add(mntmPreferences);
mntmPreferences.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
PreferencesDialog dialog = new PreferencesDialog();
dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
dialog.setVisible(true);
}
});
mntmPreferences.setIcon(Application.icon("applications-system"));
JMenuItem mntmRestore = new JMenuItem("Restore...");
mntmRestore.setIcon(Application.icon("edit-undo"));
mntmRestore.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
RestoreDialog dialog = new RestoreDialog();
dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
dialog.setVisible(true);
}
});
mnFile.add(mntmRestore);
JSeparator separator = new JSeparator();
mnFile.add(separator);
mnFile.add(mntmExit);
mnMods = new JMenu("Mods");
menuBar.add(mnMods);
JMenuItem mntmGotoMinecraftMods = new JMenuItem("Minecraft Mods Forum");
mntmGotoMinecraftMods.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent arg0) {
Application