- Timestamp:
- 2014-11-04T15:38:17+01:00 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/ImageProvider.java
r7695 r7706 683 683 } 684 684 } 685 if ( mediatype != null && mediatype.contains("image/svg+xml")) {685 if ("image/svg+xml".equals(mediatype)) { 686 686 String s = new String(bytes, StandardCharsets.UTF_8); 687 687 URI uri = getSvgUniverse().loadSVG(new StringReader(s), URLEncoder.encode(s, "UTF-8")); … … 697 697 // This can be removed if someday Oracle fixes https://bugs.openjdk.java.net/browse/JDK-6788458 698 698 // hg.openjdk.java.net/jdk7u/jdk7u/jdk/file/828c4fedd29f/src/share/classes/com/sun/imageio/plugins/png/PNGImageReader.java#l656 699 return new ImageResource(read(new ByteArrayInputStream(bytes), false, true)); 699 Image img = read(new ByteArrayInputStream(bytes), false, true); 700 return img == null ? null : new ImageResource(img); 700 701 } catch (IOException e) { 701 702 Main.warn("IOException while reading image: "+e.getMessage());
Note:
See TracChangeset
for help on using the changeset viewer.