Skip to content

Commit 78d9484

Browse files
committed
Update UILoader.
1 parent 4bbcf3b commit 78d9484

2 files changed

Lines changed: 4 additions & 12 deletions

File tree

sierra-test/src/main/java/org/httprpc/sierra/test/CustomBindingTest.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,15 @@ public void run() {
5757
}
5858

5959
public static void main(String[] args) throws IOException, ClassNotFoundException {
60+
var classLoader = ClassLoader.getSystemClassLoader();
61+
6062
var bindings = new Properties();
6163

62-
try (var inputStream = CustomBindingTest.class.getResourceAsStream("/bindings.properties")) {
64+
try (var inputStream = classLoader.getResourceAsStream("bindings.properties")) {
6365
bindings.load(inputStream);
6466
}
6567

66-
UILoader.bind(bindings);
68+
UILoader.bind(bindings, classLoader);
6769

6870
FlatLightLaf.setup();
6971

sierra/src/main/java/org/httprpc/sierra/UILoader.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1028,16 +1028,6 @@ public static <C extends JComponent> void bind(String tag, Class<C> type, Suppli
10281028
suppliers.put(tag, supplier);
10291029
}
10301030

1031-
/**
1032-
* Applies multiple bindings.
1033-
*
1034-
* @param bindings
1035-
* The bindings to apply.
1036-
*/
1037-
public static void bind(Properties bindings) throws ClassNotFoundException {
1038-
bind(bindings, ClassLoader.getSystemClassLoader());
1039-
}
1040-
10411031
/**
10421032
* Applies multiple bindings.
10431033
*

0 commit comments

Comments
 (0)