Changeset 5764 in josm for trunk


Ignore:
Timestamp:
2013-03-08T19:35:50+01:00 (7 years ago)
Author:
Don-vip
Message:

use of getPoint2D() instead of getPoint() when possible

Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/mapmode/DrawAction.java

    r5741 r5764  
    10101010            // fall through to default action.
    10111011            // (for semi-parallel lines, intersection might be miles away!)
    1012             if (Main.map.mapView.getPoint(n).distance(Main.map.mapView.getPoint(intersection)) < snapToIntersectionThreshold) {
     1012            if (Main.map.mapView.getPoint2D(n).distance(Main.map.mapView.getPoint2D(intersection)) < snapToIntersectionThreshold) {
    10131013                n.setEastNorth(intersection);
    10141014                return;
  • trunk/src/org/openstreetmap/josm/gui/SelectionManager.java

    r5500 r5764  
    309309            // nodes
    310310            for (Node n : nc.getCurrentDataSet().getNodes()) {
    311                 if (n.isSelectable() && lasso.contains(nc.getPoint(n))) {
     311                if (n.isSelectable() && lasso.contains(nc.getPoint2D(n))) {
    312312                    selection.add(n);
    313313                }
     
    321321                if (alt) {
    322322                    for (Node n : w.getNodes()) {
    323                         if (!n.isIncomplete() && lasso.contains(nc.getPoint(n))) {
     323                        if (!n.isIncomplete() && lasso.contains(nc.getPoint2D(n))) {
    324324                            selection.add(w);
    325325                            break;
Note: See TracChangeset for help on using the changeset viewer.