UIDefaultsLoader: moved some code to where it belongs (for previous commit)

This commit is contained in:
Karl Tauber
2020-09-12 18:38:35 +02:00
parent 1697735162
commit b3c76c21b4

View File

@@ -198,13 +198,6 @@ class UIDefaultsLoader
} }
} }
Function<String, String> propertiesGetter = key -> {
return properties.getProperty( key );
};
Function<String, String> resolver = value -> {
return resolveValue( value, propertiesGetter );
};
// get (and remove) globals, which override all other defaults that end with same suffix // get (and remove) globals, which override all other defaults that end with same suffix
HashMap<String, String> globals = new HashMap<>(); HashMap<String, String> globals = new HashMap<>();
Iterator<Entry<Object, Object>> it = properties.entrySet().iterator(); Iterator<Entry<Object, Object>> it = properties.entrySet().iterator();
@@ -228,6 +221,13 @@ class UIDefaultsLoader
} }
} }
Function<String, String> propertiesGetter = key -> {
return properties.getProperty( key );
};
Function<String, String> resolver = value -> {
return resolveValue( value, propertiesGetter );
};
// parse and add properties to UI defaults // parse and add properties to UI defaults
for( Map.Entry<Object, Object> e : properties.entrySet() ) { for( Map.Entry<Object, Object> e : properties.entrySet() ) {
String key = (String) e.getKey(); String key = (String) e.getKey();