Ignore:
Timestamp:
2009-08-23T22:37:39+02:00 (16 years ago)
Author:
Gubaer
Message:

fixed #3261: Use the "name:$CURRENT_LOCALE" name in the JOSM UI instead of "name" when it exists
new: new checkbox in LAF preferences for enabling/disabling localized names for primitives

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/preferences/LafPreference.java

    r1742 r1990  
    3838    private JCheckBox showSplashScreen = new JCheckBox(tr("Show splash screen at startup"));
    3939    private JCheckBox showID = new JCheckBox(tr("Show object ID in selection lists"));
     40    private JCheckBox showLocalizedName = new JCheckBox(tr("Show localized name in selection lists"));
    4041    private JCheckBox drawHelperLine = new JCheckBox(tr("Draw rubber-band helper line"));
    4142    private JCheckBox modeless = new JCheckBox(tr("Modeless working (Potlatch style)"));
     
    5051            // no exception? Then Go!
    5152            lafCombo.addItem(
    52                 new UIManager.LookAndFeelInfo(((javax.swing.LookAndFeel)Oquaqua).getName(), "ch.randelshofer.quaqua.QuaquaLookAndFeel")
     53                    new UIManager.LookAndFeelInfo(((javax.swing.LookAndFeel)Oquaqua).getName(), "ch.randelshofer.quaqua.QuaquaLookAndFeel")
    5354            );
    5455        } catch (Exception ex) {
     
    8586        panel.add(showID, GBC.eop().insets(20, 0, 0, 0));
    8687
     88        // Show localized names
     89        showLocalizedName.setToolTipText(tr("Show localized name in selection lists, if available"));
     90        showLocalizedName.setSelected(Main.pref.getBoolean("osm-primitives.localize-name", true));
     91        panel.add(showLocalizedName, GBC.eop().insets(20, 0, 0, 0));
     92
    8793        drawHelperLine.setToolTipText(tr("Draw rubber-band helper line"));
    8894        drawHelperLine.setSelected(Main.pref.getBoolean("draw.helper-line", true));
     
    107113        Main.pref.put("draw.splashscreen", showSplashScreen.isSelected());
    108114        Main.pref.put("osm-primitives.showid", showID.isSelected());
     115        Main.pref.put("osm-primitives.localize-name", showLocalizedName.isSelected());
    109116        Main.pref.put("draw.helper-line", drawHelperLine.isSelected());
    110117        Main.pref.put("modeless", modeless.isSelected());
    111118        return Main.pref.put("laf", ((LookAndFeelInfo)lafCombo.getSelectedItem()).getClassName());
    112119    }
    113 
    114120}
Note: See TracChangeset for help on using the changeset viewer.