Contents

setNeedsDisplayInMapRect:zoomScale:

Invalidates the view in the given map rectangle but only at the specified zoom scale.

Declaration

- (void) setNeedsDisplayInMapRect:(MKMapRect) mapRect zoomScale:(MKZoomScale) zoomScale;

Parameters

  • mapRect:

    The portion of the overlay that needs to be updated. This value is specified using a map rectangle and not view coordinates. You can convert from a view rectangle to a map rectangle using the Maprectforrect: method.

  • zoomScale:

    The zoom scale for which you want to invalidate the overlay.

Discussion

Marking a rectangle as invalid causes that portion of the view to be redrawn during the next update cycle. This method invalidates the overlay only when it is drawn at the specified zoom scale.

See Also

Drawing the overlay