Ticket #8655: unnecessary-toString.diff

File unnecessary-toString.diff, 3.7 KB (added by Skyman, 11 years ago)
  • src/org/openstreetmap/josm/gui/help/HelpBrowser.java

     
    385385                                "<html>Failed to open help page for url {0}.<br>"
    386386                                + "This is most likely due to a network problem, please check<br>"
    387387                                + "your internet connection</html>",
    388                                 url.toString()
     388                                url
    389389                        ),
    390390                        tr("Failed to open URL"),
    391391                        JOptionPane.ERROR_MESSAGE,
  • src/org/openstreetmap/josm/gui/help/HelpBrowserHistory.java

     
    5151    public void setCurrentUrl(String url) {
    5252        boolean add=true;
    5353
    54         if (historyPos >= 0 && historyPos < history.size() && history.get(historyPos).toString().equals(url.toString())) {
     54        if (historyPos >= 0 && historyPos < history.size() && history.get(historyPos).equals(url.toString())) {
    5555            add = false;
    5656        } else if (historyPos == history.size() -1) {
    5757            // do nothing just append
     
    6464        }
    6565        if(add)
    6666        {
    67           history.add(url);
    68           historyPos = history.size()-1;
     67            history.add(url);
     68            historyPos = history.size()-1;
    6969        }
    7070        setChanged();
    7171        notifyObservers();
  • src/org/openstreetmap/josm/plugins/PluginListParser.java

     
    3737                    new ByteArrayInputStream(manifest.getBytes("utf-8")),
    3838                    name.substring(0, name.length() - 4),
    3939                    url
    40             );
     40                    );
    4141        } catch(UnsupportedEncodingException e) {
    4242            throw new PluginListParseException(tr("Failed to create plugin information from manifest for plugin ''{0}''", name), e);
    4343        } catch (PluginException e) {
     
    7272                    C;
    7373                }
    7474                B;
    75             */
     75             */
    7676            for (String line = r.readLine(); line != null; line = r.readLine()) {
    7777                if (line.startsWith("\t")) {
    7878                    line = line.substring(1);
     
    8686                addPluginInformation(ret, name, url, manifest.toString());
    8787                String x[] = line.split(";");
    8888                if(x.length != 2)
    89                   throw new IOException(tr("Illegal entry in plugin list."));
     89                    throw new IOException(tr("Illegal entry in plugin list."));
    9090                name = x[0];
    9191                url = x[1];
    9292                manifest = new StringBuilder();
     
    102102    private static void addPluginInformation(List<PluginInformation> ret, String name, String url, String manifest) {
    103103        try {
    104104            if (name != null) {
    105                 PluginInformation info = createInfo(name, url, manifest.toString());
     105                PluginInformation info = createInfo(name, url, manifest);
    106106                if (info != null) {
    107107                    for (PluginProxy plugin : PluginHandler.pluginList) {
    108108                        if (plugin.getPluginInformation().name.equals(info.getName())) {