Ignore:
Timestamp:
2015-05-11T10:52:33+02:00 (9 years ago)
Author:
Don-vip
Message:

code style - Useless parentheses around expressions should be removed to prevent any misunderstanding

File:
1 edited

Legend:

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

    r8342 r8345  
    12921292    public static double perDist(Point2D pt, Point2D a, Point2D b) {
    12931293        if (pt != null && a != null && b != null) {
    1294             double pd = (
     1294            double pd =
    12951295                    (a.getX()-pt.getX())*(b.getX()-a.getX()) -
    1296                     (a.getY()-pt.getY())*(b.getY()-a.getY()) );
     1296                    (a.getY()-pt.getY())*(b.getY()-a.getY());
    12971297            return Math.abs(pd) / a.distance(b);
    12981298        }
     
    13101310    public static Point2D project(Point2D pt, Point2D a, Point2D b) {
    13111311        if (pt != null && a != null && b != null) {
    1312             double r = ((
     1312            double r = (
    13131313                    (pt.getX()-a.getX())*(b.getX()-a.getX()) +
    13141314                    (pt.getY()-a.getY())*(b.getY()-a.getY()) )
    1315                     / a.distanceSq(b));
     1315                    / a.distanceSq(b);
    13161316            return project(r, a, b);
    13171317        }
Note: See TracChangeset for help on using the changeset viewer.