Changeset 4900 in josm for trunk/src/org/openstreetmap


Ignore:
Timestamp:
2012-02-04T22:41:17+01:00 (8 years ago)
Author:
stoecker
Message:

fix #7358 - custom shortcuts broken

Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/Preferences.java

    r4895 r4900  
    9595    protected final SortedMap<String, String> colornames = new TreeMap<String, String>();
    9696
    97     /** Mapping for list settings. Must not conatin null values */
     97    /** Mapping for list settings. Must not contain null values */
    9898    protected final SortedMap<String, List<String>> collectionProperties = new TreeMap<String, List<String>>();
    9999    /** Defaults, can contain null values */
     
    376376    }
    377377
    378     synchronized public List<String> getAllPrefixKeys(final String prefix) {
     378    synchronized public List<String> getAllPrefixCollectionKeys(final String prefix) {
    379379        final List<String> all = new LinkedList<String>();
    380         for (final Entry<String,String> e : properties.entrySet()) {
    381             if (e.getKey().startsWith(prefix)) {
    382                 all.add(e.getKey());
     380        for (final String e : collectionProperties.keySet()) {
     381            if (e.startsWith(prefix)) {
     382                all.add(e);
    383383            }
    384384        }
  • trunk/src/org/openstreetmap/josm/tools/Shortcut.java

    r4897 r4900  
    314314        // (2) User defined shortcuts
    315315        LinkedList<Shortcut> shortcuts = new LinkedList<Shortcut>();
    316         for(String s : Main.pref.getAllPrefixKeys("shortcut.entry.")) {
     316        for(String s : Main.pref.getAllPrefixCollectionKeys("shortcut.entry.")) {
    317317            shortcuts.add(new Shortcut(s));
    318318        }
Note: See TracChangeset for help on using the changeset viewer.