mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-08 07:55:13 +00:00
Version 5.0: Separated map projection and view transform.
This commit is contained in:
parent
53723844a0
commit
c7cb2efcdb
47 changed files with 401 additions and 382 deletions
|
|
@ -27,7 +27,7 @@ namespace MapControl
|
|||
|
||||
if (cbbox != null)
|
||||
{
|
||||
var center = LocationToPoint(cbbox.Center);
|
||||
var center = LocationToMap(cbbox.Center);
|
||||
|
||||
return new Rect(
|
||||
center.X - cbbox.Width / 2d, center.Y - cbbox.Height / 2d,
|
||||
|
|
@ -39,7 +39,7 @@ namespace MapControl
|
|||
|
||||
public override BoundingBox RectToBoundingBox(Rect rect)
|
||||
{
|
||||
var center = PointToLocation(new Point(rect.X + rect.Width / 2d, rect.Y + rect.Height / 2d));
|
||||
var center = MapToLocation(new Point(rect.X + rect.Width / 2d, rect.Y + rect.Height / 2d));
|
||||
|
||||
return new CenteredBoundingBox(center, rect.Width, rect.Height); // width and height in meters
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue