Ignore:
Timestamp:
2017-04-13T00:03:15+02:00 (7 years ago)
Author:
Don-vip
Message:

see #7427 - sonar - squid:S1226 - Method parameters, caught exceptions and foreach variables should not be reassigned

File:
1 edited

Legend:

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

    r11883 r11891  
    14441444        TileXY t1, t2;
    14451445        if (coordinateConverter.requiresReprojection()) {
    1446             Projection projCurrent = Main.getProjection();
    14471446            Projection projServer = Projections.getProjectionByCode(tileSource.getServerCRS());
    1448             bounds = new ProjectionBounds(
     1447            ProjectionBounds projBounds = new ProjectionBounds(
    14491448                    new EastNorth(coordinateConverter.shiftDisplayToServer(bounds.getMin())),
    14501449                    new EastNorth(coordinateConverter.shiftDisplayToServer(bounds.getMax())));
    1451             bounds = projServer.getEastNorthBoundsBox(bounds, projCurrent);
    1452             t1 = tileSource.projectedToTileXY(bounds.getMin().toProjected(), zoom);
    1453             t2 = tileSource.projectedToTileXY(bounds.getMax().toProjected(), zoom);
     1450            ProjectionBounds bbox = projServer.getEastNorthBoundsBox(projBounds, Main.getProjection());
     1451            t1 = tileSource.projectedToTileXY(bbox.getMin().toProjected(), zoom);
     1452            t2 = tileSource.projectedToTileXY(bbox.getMax().toProjected(), zoom);
    14541453        } else {
    14551454            IProjected topLeftUnshifted = coordinateConverter.shiftDisplayToServer(bounds.getMin());
Note: See TracChangeset for help on using the changeset viewer.