- Timestamp:
- 2020-10-08T20:26:02+02:00 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/preferences/NamedColorProperty.java
r16843 r17118 37 37 */ 38 38 public NamedColorProperty(String category, String source, String name, Color defaultValue) { 39 super(getKey(category, source, name), defaultValue);39 super(getKey(category, source, name), getUIColor("JOSM." + getKey(category, source, name), defaultValue)); 40 40 CheckParameterUtil.ensureParameterNotNull(category, "category"); 41 41 CheckParameterUtil.ensureParameterNotNull(name, "name"); … … 58 58 CheckParameterUtil.ensureParameterNotNull(name, "name"); 59 59 return NAMED_COLOR_PREFIX + category + "." + (source == null ? "" : source + ".") + name; 60 } 61 62 private static Color getUIColor(String uiKey, Color defaultValue) { 63 Color color = UIManager.getColor(uiKey); 64 return color != null ? color : defaultValue; 60 65 } 61 66
Note:
See TracChangeset
for help on using the changeset viewer.