I am trying to draw different shapes on an MKMapView, like circles and squares. I would like them to be able to receive tapGestures; however, it looks like there is no way doing so using MKOverlay. I, also, want these shapes to be fixed-size in relation to the map itself, so MKAnnotations do not work since their size is fixed in relation to the "image" value they show(not to the map itself). So is there any other way to draw these gesture-receiving shapes on an MKMapView? Or do I miss something in MKAnnotation/MKOverlay?
Asked
Active
Viewed 15 times
0
-
individually no, they won't receive touches unless you make your custom overlay classes but map has a tap gesture already. now you need to identify which overlay you tapped. this will help - https://stackoverflow.com/questions/20858108 – Blind Ninja Feb 16 '22 at 05:07