Fix route/track on map in direction compass mode
This commit is contained in:
parent
61f786e082
commit
c0ed1d1eca
1 changed files with 4 additions and 1 deletions
|
@ -950,8 +950,9 @@ public class OsmandMapTileView implements IMapDownloaderCallback {
|
|||
}
|
||||
} else if (tileBoxHeightPx > 0) {
|
||||
tbh = (int) (tileBoxHeightPx * border);
|
||||
dy = (tb.getCenterPixelY() * 2 - tileBoxHeightPx) / 2 - marginTopPx;
|
||||
dy = (tb.getPixHeight() - tileBoxHeightPx) / 2 - marginTopPx;
|
||||
}
|
||||
dy += tb.getCenterPixelY() - tb.getPixHeight() / 2;
|
||||
tb.setPixelDimensions(tbw, tbh);
|
||||
|
||||
double clat = bottom / 2 + top / 2;
|
||||
|
@ -983,6 +984,7 @@ public class OsmandMapTileView implements IMapDownloaderCallback {
|
|||
tbh = (int) (tileBoxHeightPx * border);
|
||||
dy = (tb.getPixHeight() - tileBoxHeightPx) / 2 - marginTopPx;
|
||||
}
|
||||
dy += tb.getCenterPixelY() - tb.getPixHeight() / 2;
|
||||
tb.setPixelDimensions(tbw, tbh);
|
||||
|
||||
if (dy != 0) {
|
||||
|
@ -1006,6 +1008,7 @@ public class OsmandMapTileView implements IMapDownloaderCallback {
|
|||
tbh = tileBoxHeightPx;
|
||||
dy = (tb.getPixHeight() - tileBoxHeightPx) / 2 - marginTopPx;
|
||||
}
|
||||
dy += tb.getCenterPixelY() - tb.getPixHeight() / 2;
|
||||
tb.setPixelDimensions(tbw, tbh);
|
||||
tb.setLatLonCenter(clat, clon);
|
||||
tb.setZoom(zoom);
|
||||
|
|
Loading…
Reference in a new issue