开发者

What is the delegate method that is called when an MKPinAnnotationView is touched?

开发者 https://www.devze.com 2022-12-17 09:21 出处:网络
I have been searching for this all night and I have just so frustrated. When a MKPinAnnotationView is clicked, the name and the subtitle comes up. I also want to center that point on the view. I figur

I have been searching for this all night and I have just so frustrated. When a MKPinAnnotationView is clicked, the name and the subtitle comes up. I also want to center that point on the view. I figured there was some method I had to override because the information that pops up happened without me having to code it. Hopefully this was clear enough for you all.

And in the mean time, I feel like 开发者_StackOverflow社区there is some hidden guide on this use of MKMaps and other classes. Either that or it is terribly documented because I am having a lot of trouble finding information. Thanks.


Have you tried overriding setSelected:animated:? (defined in MKAnnotationView)


-(void)mapView:(MKMapView *)mapView1 didSelectAnnotationView:(MKAnnotationView *)view{
}

This is the method that is called when you tap on a pin.

0

精彩评论

暂无评论...
验证码 换一张
取 消