Browse Source

Update JSVG to version 0.0.3

pull/326/head
Jannis Weis 2 years ago
parent
commit
664ac791c2
No known key found for this signature in database
GPG Key ID: 7C9D8D4B558049AB
  1. 2
      gradle.properties
  2. 7
      property-loader/src/main/java/com/github/weisj/darklaf/properties/icons/IconLoader.java

2
gradle.properties

@ -29,7 +29,7 @@ net.ltgt.errorprone.version = 2.0.2
# Dependencies # Dependencies
# Libraries # Libraries
jsvg.version = 0.0.2 jsvg.version = 0.0.3
swingDsl.version = 0.1.3 swingDsl.version = 0.1.3
swingx.version = 1.6.1 swingx.version = 1.6.1
nullabilityAnnotations.version = 23.0.0 nullabilityAnnotations.version = 23.0.0

7
property-loader/src/main/java/com/github/weisj/darklaf/properties/icons/IconLoader.java

@ -77,8 +77,11 @@ public final class IconLoader implements IconResolver {
loader = new SVGLoader(); loader = new SVGLoader();
} }
static SVGLoader svgLoader() { static @NotNull SVGLoader svgLoader() {
return loader; // SVGLoader is not thread safe. For the EDT we use a cached version to avoid UI slow downs.
// All other cases are probably fine with the overhead of creating a new SVGLoader instance.
if (SwingUtilities.isEventDispatchThread()) return loader;
return new SVGLoader();
} }
/** /**

Loading…
Cancel
Save