Changeset 35812 in osm for applications/editors/josm


Ignore:
Timestamp:
2021-08-25T20:15:47+02:00 (3 years ago)
Author:
Don-vip
Message:

fix a few warnings

Location:
applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes/gui/GuiContainer.java

    r34925 r35812  
    122122
    123123    /**
     124     * Returns meters per pixel
    124125     * @return meters per pixel
    125126     */
  • applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes/gui/Path.java

    r33085 r35812  
    355355                final double r1 = radius(a1) - s * ws;
    356356
    357                 final Curve c1 = new Curve(prev, fromRadius - ws, r1, offsetAngle(prev, a1), l1, fromAngle);
     357                final Curve c1 = new Curve(prev, fromRadius - ws, r1, a1, l1, fromAngle);
    358358
    359359                final double l2 = m2 - m1;
     
    369369                final double r1 = radius(a1) - s * ws;
    370370
    371                 final Curve c1 = new Curve(prev, fromRadius - s * ws, r1, offsetAngle(prev, a1), l1, fromAngle);
     371                final Curve c1 = new Curve(prev, fromRadius - s * ws, r1, a1, l1, fromAngle);
    372372
    373373                final double w = ws + (ML - m1) * (we - ws) / (m2 - m1);
     
    381381                final double r2 = radius(a2) - s * we;
    382382
    383                 final Curve c2 = new Curve(prev, fromRadius - s * w, r2, offsetAngle(prev, a2), l2, fromAngle);
     383                final Curve c2 = new Curve(prev, fromRadius - s * w, r2, a2, l2, fromAngle);
    384384
    385385                return new Curve(c2, r2, toRadius - s * we, angle - a2, ML - m2);
     
    388388                final double w2 = we - (m2 - ML) * (we - ws) / (m2 - m1);
    389389
    390                 return new Curve(prev, fromRadius - s * w1, toRadius - s * w2, offsetAngle(prev, angle), length,
     390                return new Curve(prev, fromRadius - s * w1, toRadius - s * w2, angle, length,
    391391                        fromAngle);
    392392            }
     
    401401        }
    402402
    403         private double offsetAngle(Path prev, double a) {
    404             return a; // + GuiUtil.normalize(previous.getEndAngle()
    405             // - prev.getEndAngle());
    406         }
    407 
    408403        private Path simpleOffset(Path prev, double w) {
    409404            final double s = signum(angle);
    410             return new Curve(prev, fromRadius - s * w, toRadius - s * w, offsetAngle(prev, angle), length, fromAngle);
     405            return new Curve(prev, fromRadius - s * w, toRadius - s * w, angle, length, fromAngle);
    411406        }
    412407
  • applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes/model/Road.java

    r34976 r35812  
    8686
    8787        /**
     88         * Returns the turns <em>onto</em> this road at this end
    8889         * @return the turns <em>onto</em> this road at this end
    8990         */
  • applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes/model/Turn.java

    r34976 r35812  
    6262
    6363        final List<Way> tmp = TurnlanesUtils.getMemberWays(r, Constants.TURN_ROLE_VIA);
    64         final LinkedList<Road> via = new LinkedList<>();
     64        final List<Road> via = new LinkedList<>();
    6565
    6666        final Road.End fromRoadEnd = c.getJunction(TurnlanesUtils.lineUp(from, tmp.get(0))).getRoadEnd(from);
     
    9696        }
    9797        final Road.End toRoadEnd = c.getJunction(n).getRoadEnd(to);
    98         n = TurnlanesUtils.getOppositeEnd(to, n);
    9998
    10099        final Set<Turn> result = new HashSet<>();
  • applications/editors/josm/plugins/turnlanes/src/org/openstreetmap/josm/plugins/turnlanes/model/TurnlanesUtils.java

    r34978 r35812  
    101101
    102102    /**
    103      *
     103     * Lines up given ways
    104104     * @param a first way
    105105     * @param b second way
Note: See TracChangeset for help on using the changeset viewer.