Dropping pins on zoomed maps #1

Closed
neilang opened this Issue Feb 23, 2011 · 1 comment

1 participant

@neilang
Owner

There is an issue with adding a pin after the zoom scale has been changed.

Simple workaround is to reset the zoom scale to 1.0 before adding the pin.

e.g.

// Calculate zoomed out position
CGPoint point = CGPointMake(location.x / self.mapView.zoomScale, location.y / self.mapView.zoomScale);

// Zoom to default level
[self.mapView setZoomScale:1.0 animated:YES];

// Focus on correct position
[self.mapView centreOnPoint:point animated:YES];

// Add annotation at new point
... = [NAAnnotation annotationWithPoint:point];
@neilang
Owner

Fixed with the release of v2.0

@neilang neilang closed this May 6, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment