Changeset 593 for AE/installer2/src/net/oni2/aeinstaller/gui/settings
- Timestamp:
- Dec 31, 2012, 2:48:32 PM (12 years ago)
- Location:
- AE/installer2/src/net/oni2/aeinstaller/gui/settings
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
AE/installer2/src/net/oni2/aeinstaller/gui/settings/SettingsDialog.java
r592 r593 9 9 import javax.swing.JComboBox; 10 10 import javax.swing.JComponent; 11 import javax.swing.J Frame;11 import javax.swing.JDialog; 12 12 import javax.swing.JOptionPane; 13 13 import javax.swing.KeyStroke; 14 import javax.swing.SwingUtilities;15 14 import javax.swing.UIManager; 16 15 … … 23 22 * @author Christian Illy 24 23 */ 25 public class SettingsDialog extends J Frame{24 public class SettingsDialog extends JDialog { 26 25 private static final long serialVersionUID = -5719515325671846620L; 27 26 … … 31 30 private BuildResult result = SwingJavaBuilder.build(this, bundle); 32 31 33 private static SettingsDialog openWindow = null;34 35 32 private JComboBox cmbLaF; 36 33 private LaFComboModel laFModel; 37 34 38 35 /** 39 * Open the Settings dialog if not currently opened or brings the existing 40 * one to front 36 * Open the settings 41 37 */ 42 public static void openWindow() { 43 if (openWindow != null) { 44 SwingUtilities.invokeLater(new Runnable() { 45 46 @Override 47 public void run() { 48 openWindow.toFront(); 49 openWindow.repaint(); 50 } 51 }); 52 } else { 53 new SettingsDialog().setVisible(true); 54 } 55 } 56 57 private SettingsDialog() { 58 openWindow = this; 38 public SettingsDialog() { 59 39 setMinimumSize(new Dimension(500, (int) getSize().getHeight() + 0)); 60 40 … … 85 65 86 66 @SuppressWarnings("unused") 87 private void close() {88 openWindow = null;89 }90 91 @SuppressWarnings("unused")92 67 private boolean save() { 93 68 Settings set = Settings.getInstance(); -
AE/installer2/src/net/oni2/aeinstaller/gui/settings/SettingsDialog.yml
r591 r593 1 J Frame:1 JDialog: 2 2 name: frame 3 3 title: frame.title … … 5 5 locationRelativeTo: null 6 6 defaultCloseOperation: disposeOnClose 7 onWindowClosed: [close]8 iconImage: img.kdt7 iconImage: img.ae 8 modalityType: applicationModal 9 9 content: 10 10 - JButton(name=btnOk, text=btnOk, onAction=[save,dispose])
Note:
See TracChangeset
for help on using the changeset viewer.