Updated MapProjection

This commit is contained in:
ClemensFischer 2025-12-30 08:27:52 +01:00
parent 5d8f1b5ff0
commit 612a4048c0
2 changed files with 9 additions and 13 deletions

View file

@ -286,18 +286,12 @@ namespace MapControl
private void ArrangeElement(FrameworkElement element, BoundingBox boundingBox)
{
Rect? mapRect = null;
Rect? mapRect;
var rotation = 0d;
if (boundingBox is LatLonBox latLonBox)
{
var rotatedRect = parentMap.MapProjection.LatLonBoxToMap(latLonBox);
if (rotatedRect.HasValue)
{
mapRect = rotatedRect.Value.Item1;
rotation = -rotatedRect.Value.Item2;
}
(mapRect, rotation) = parentMap.MapProjection.LatLonBoxToMap(latLonBox);
}
else
{