想通过ios sdk中的按钮在地图上放大缩小

Pri*_*ka 2 iphone map zooming uibutton ios

我想在ios sdk中添加地图上的按钮Mapview 1>放大按钮2>缩小按钮请指定任何演示或与此相关的任何代码.

cha*_*tur 5

放大

-(void)zoomInMap
{
region.span.latitudeDelta = region.span.latitudeDelta/2 ;
    region.span.longitudeDelta = region.span.longitudeDelta/2;



    region.center.latitude = mapView.centerCoordinate.latitude ;
    region.center.longitude = mapView.centerCoordinate.longitude ;
    [mapView setRegion:region animated:YES];
}
Run Code Online (Sandbox Code Playgroud)

类似地缩小.