Ignore:
Timestamp:
2014-05-09T05:32:37+02:00 (12 years ago)
Author:
Don-vip
Message:

see #8465 - replace Utils.UTF_8 by StandardCharsets.UTF_8, new in Java 7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/ImageProvider.java

    r7075 r7082  
    2424import java.net.URLDecoder;
    2525import java.net.URLEncoder;
     26import java.nio.charset.StandardCharsets;
    2627import java.util.ArrayList;
    2728import java.util.Arrays;
     
    537538                } else {
    538539                    try {
    539                         bytes = URLDecoder.decode(data, "UTF-8").getBytes(Utils.UTF_8);
     540                        bytes = URLDecoder.decode(data, "UTF-8").getBytes(StandardCharsets.UTF_8);
    540541                    } catch (IllegalArgumentException ex) {
    541542                        Main.warn("Unable to decode URL data part: "+ex.getMessage() + " (" + data + ")");
     
    544545                }
    545546                if (mediatype != null && mediatype.contains("image/svg+xml")) {
    546                     String s = new String(bytes, Utils.UTF_8);
     547                    String s = new String(bytes, StandardCharsets.UTF_8);
    547548                    URI uri = getSvgUniverse().loadSVG(new StringReader(s), URLEncoder.encode(s, "UTF-8"));
    548549                    SVGDiagram svg = getSvgUniverse().getDiagram(uri);
Note: See TracChangeset for help on using the changeset viewer.