mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2025-12-06 07:12:04 +01:00
Update MapPath.cs
This commit is contained in:
parent
421f323116
commit
aa63ec813c
|
|
@ -117,9 +117,16 @@ namespace MapControl
|
|||
|
||||
var point = parentMap.MapProjection.LocationToMap(location);
|
||||
|
||||
if (point.HasValue && double.IsInfinity(point.Value.Y))
|
||||
if (point.HasValue)
|
||||
{
|
||||
point = null;
|
||||
if (point.Value.Y == double.PositiveInfinity)
|
||||
{
|
||||
point = new Point(point.Value.X, 1e9);
|
||||
}
|
||||
else if (point.Value.Y == double.NegativeInfinity)
|
||||
{
|
||||
point = new Point(point.Value.X, -1e9);
|
||||
}
|
||||
}
|
||||
|
||||
return point;
|
||||
|
|
|
|||
Loading…
Reference in a new issue