Changeset 8404 in josm for trunk/src/org/openstreetmap/josm/data/preferences/ColorProperty.java
- Timestamp:
- 2015-05-21T01:18:35+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/preferences/ColorProperty.java
r7937 r8404 3 3 4 4 import java.awt.Color; 5 import java.util.Locale; 5 6 6 7 import org.openstreetmap.josm.Main; … … 14 15 15 16 private final String name; 16 17 17 18 /** 18 19 * Constructs a new {@code ColorProperty}. … … 24 25 this.name = colName; 25 26 } 26 27 27 28 @Override 28 29 public Color get() { … … 34 35 return Main.pref.putColor(getColorKey(name), value); 35 36 } 36 37 37 38 /** 38 39 * Replies the color key used in JOSM preferences for this property. … … 41 42 */ 42 43 public static String getColorKey(String colName) { 43 return colName == null ? null : colName.toLowerCase( ).replaceAll("[^a-z0-9]+",".");44 return colName == null ? null : colName.toLowerCase(Locale.ENGLISH).replaceAll("[^a-z0-9]+","."); 44 45 } 45 46
Note:
See TracChangeset
for help on using the changeset viewer.