Changeset 619 in josm for trunk


Ignore:
Timestamp:
2008-04-21T17:28:14+02:00 (16 years ago)
Author:
gebner
Message:

Put the code to display the currently mouse-overed object in the status bar
back into the "try/catch hack" (to ignore ConcurrentModificationExceptions),
where it originally was. Stops ennerving exceptions while splitting ways.

File:
1 edited

Legend:

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

    r617 r619  
    144144                                        continue;
    145145
    146                                 OsmPrimitive osmNearest = null;
    147                                 // Set the text label in the bottom status bar
    148                                 osmNearest = mv.getNearest(ms.mousePos);
    149                                 if (osmNearest != null) {
    150                                         NameVisitor visitor = new NameVisitor();
    151                                         osmNearest.visit(visitor);
    152                                         nameText.setText(visitor.name);
    153                                 } else
    154                                         nameText.setText("(no object)");                               
    155 
    156146                                // This try/catch is a hack to stop the flooding bug reports about this.
    157147                                // The exception needed to handle with in the first place, means that this
     
    159149                                // the data.
    160150                                try {
     151                                        OsmPrimitive osmNearest = null;
     152                                        // Set the text label in the bottom status bar
     153                                        osmNearest = mv.getNearest(ms.mousePos);
     154                                        if (osmNearest != null) {
     155                                                NameVisitor visitor = new NameVisitor();
     156                                                osmNearest.visit(visitor);
     157                                                nameText.setText(visitor.name);
     158                                        } else
     159                                                nameText.setText("(no object)");
     160
    161161                                        // Popup Information
    162162                                        if ((ms.modifiers & MouseEvent.BUTTON2_DOWN_MASK) != 0 ) {
Note: See TracChangeset for help on using the changeset viewer.