Ignore:
Timestamp:
2006-01-22T16:10:57+01:00 (18 years ago)
Author:
imi
Message:
  • removed UTM (too complex)
  • added please wait dialog for down-/uploading
  • added created_by=JOSM to every new element
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/org/openstreetmap/josm/gui/PreferenceDialog.java

    r38 r43  
    1515import javax.swing.JCheckBox;
    1616import javax.swing.JComboBox;
    17 import javax.swing.JComponent;
    1817import javax.swing.JDialog;
    1918import javax.swing.JLabel;
     
    5150                public void actionPerformed(ActionEvent e) {
    5251                        Main.pref.laf = (LookAndFeelInfo)lafCombo.getSelectedItem();
    53                         Projection projection = (Projection)projectionCombo.getSelectedItem();
    54                         projection.commitConfigurationPanel();
    55                         Main.pref.setProjection(projection);
     52                        Main.pref.setProjection((Projection)projectionCombo.getSelectedItem());
    5653                        Main.pref.osmDataServer = osmDataServer.getText();
    5754                        Main.pref.osmDataUsername = osmDataUsername.getText();
     
    9996         * Combobox with all projections available
    10097         */
    101         JComboBox projectionCombo = new JComboBox(Preferences.allProjections.clone());
     98        JComboBox projectionCombo = new JComboBox(Preferences.allProjections);
    10299        /**
    103100         * The main tab panel.
     
    160157                        }
    161158                }
    162                 JButton projectionDetail = new JButton("Configure");
    163                 projectionDetail.addActionListener(new ActionListener(){
    164                         public void actionPerformed(ActionEvent e) {
    165                                 Projection p = (Projection)projectionCombo.getSelectedItem();
    166                                 JComponent configurationPanel = p.getConfigurationPanel();
    167                                 if (configurationPanel == null) {
    168                                         JOptionPane.showMessageDialog(PreferenceDialog.this,
    169                                                         "This projection does not need any configuration.");
    170                                         return;
    171                                 }
    172                                 JPanel detail = new JPanel(new GridBagLayout());
    173                                 detail.setLayout(new GridBagLayout());
    174                                 detail.add(configurationPanel, GBC.eop().fill());
    175                                 int result = JOptionPane.showConfirmDialog(
    176                                                 PreferenceDialog.this, detail, "Configuration of "+p,
    177                                                 JOptionPane.OK_CANCEL_OPTION, JOptionPane.PLAIN_MESSAGE);
    178                                 if (result != JOptionPane.OK_OPTION)
    179                                         p.getConfigurationPanel(); // rollback
    180                         }
    181                 });
    182159               
    183160                // drawRawGpsLines
     
    242219                map.add(GBC.glue(5,0), GBC.std().fill(GBC.HORIZONTAL));
    243220                map.add(projectionCombo, GBC.eol().fill(GBC.HORIZONTAL).insets(0,0,0,5));
    244                 map.add(new JLabel("Projection details:"), GBC.std());
    245                 map.add(GBC.glue(5,0), GBC.std().fill(GBC.HORIZONTAL));
    246                 map.add(projectionDetail, GBC.eop());
    247221                map.add(Box.createVerticalGlue(), GBC.eol().fill(GBC.VERTICAL));
    248222
Note: See TracChangeset for help on using the changeset viewer.