Ignore:
Timestamp:
2014-02-25T01:31:24+01:00 (10 years ago)
Author:
Don-vip
Message:

fix some Sonar issues

Location:
trunk/src/org/openstreetmap/josm/gui/download
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/download/BookmarkSelection.java

    r6380 r6883  
    4747    /** displays information about the current download area */
    4848    private JMultilineLabel lblCurrentDownloadArea;
    49     final private JosmTextArea bboxDisplay = new JosmTextArea();
     49    private final JosmTextArea bboxDisplay = new JosmTextArea();
    5050    /** the add action */
    5151    private AddAction actAdd;
  • trunk/src/org/openstreetmap/josm/gui/download/DownloadDialog.java

    r6509 r6883  
    4848
    4949/**
    50  *
     50 * Dialog displayed to download OSM and/or GPS data from OSM server.
    5151 */
    5252public class DownloadDialog extends JDialog  {
    5353    /** the unique instance of the download dialog */
    54     static private DownloadDialog instance;
     54    private static DownloadDialog instance;
    5555
    5656    /**
     
    5959     * @return the unique instance of the download dialog
    6060     */
    61     static public DownloadDialog getInstance() {
     61    public static DownloadDialog getInstance() {
    6262        if (instance == null) {
    6363            instance = new DownloadDialog(Main.parent);
  • trunk/src/org/openstreetmap/josm/gui/download/PlaceSelection.java

    r6822 r6883  
    7070    private JTable tblSearchResults;
    7171    private DownloadDialog parent;
    72     private final static Server[] servers = new Server[]{
    73         new Server("Nominatim","http://nominatim.openstreetmap.org/search?format=xml&q=",tr("Class Type"),tr("Bounds")),
    74         //new Server("Namefinder","http://gazetteer.openstreetmap.org/namefinder/search.xml?find=",tr("Near"),trc("placeselection", "Zoom"))
     72    private static final Server[] SERVERS = new Server[] {
     73        new Server("Nominatim","http://nominatim.openstreetmap.org/search?format=xml&q=",tr("Class Type"),tr("Bounds"))
    7574    };
    76     private final JosmComboBox server = new JosmComboBox(servers);
     75    private final JosmComboBox server = new JosmComboBox(SERVERS);
    7776
    7877    private static class Server {
     
    101100        lpanel.add(new JLabel(tr("Choose the server for searching:")));
    102101        lpanel.add(server);
    103         String s = Main.pref.get("namefinder.server", servers[0].name);
    104         for (int i = 0; i < servers.length; ++i) {
    105             if (servers[i].name.equals(s)) {
     102        String s = Main.pref.get("namefinder.server", SERVERS[0].name);
     103        for (int i = 0; i < SERVERS.length; ++i) {
     104            if (SERVERS[i].name.equals(s)) {
    106105                server.setSelectedIndex(i);
    107106            }
     
    172171     * Data storage for search results.
    173172     */
    174     static private class SearchResult {
     173    private static class SearchResult {
    175174        public String name;
    176175        public String info;
     
    450449            // column 2 - Near
    451450            col3 = new TableColumn(2);
    452             col3.setHeaderValue(servers[0].thirdcol);
     451            col3.setHeaderValue(SERVERS[0].thirdcol);
    453452            col3.setResizable(true);
    454453            col3.setPreferredWidth(100);
     
    458457            // column 3 - Zoom
    459458            col4 = new TableColumn(3);
    460             col4.setHeaderValue(servers[0].fourthcol);
     459            col4.setHeaderValue(SERVERS[0].fourthcol);
    461460            col4.setResizable(true);
    462461            col4.setPreferredWidth(50);
Note: See TracChangeset for help on using the changeset viewer.