Changeset 32083 in osm


Ignore:
Timestamp:
2016-02-27T14:20:26+01:00 (9 years ago)
Author:
wiktorn
Message:

Fix regression bug from [31301]. Closes #josm#12571.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/viewer/jmapviewer/src/org/openstreetmap/gui/jmapviewer/JMapViewer.java

    r32074 r32083  
    480480     */
    481481    public Integer getLatOffset(double lat, double lon, double offset, boolean checkOutside) {
    482         Point p = tileSource.latLonToXY(lat, lon, zoom);
    483         int y = p.y - center.y - getHeight() / 2;
     482        Point p = tileSource.latLonToXY(lat + offset, lon, zoom);
     483        int y = p.y - (center.y - getHeight() / 2);
    484484        if (checkOutside && (y < 0 || y > getHeight())) {
    485485            return null;
Note: See TracChangeset for help on using the changeset viewer.