You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Tapping bunched up point annotation views should cycle among them #5166
When you tap repeatedly near a bunch of closely-spaced or overlapping GL-rendered point annotations, a different annotation is selected each time due to this cycling logic. MapKit does the same with MKAnnotationViews. This behavior is important to ensure that every annotation is reachable by the user. But MGLAnnotationView is a bit more haphazard, because we just select the first annotation view we happen to find in the query.
We should cycle among all the nearby annotations, whether they’re GL annotations, annotation views, or a mixture of both. This probably means we need to stop short-circuiting -annotationTagAtPoint:persistingResults: with -annotationViewAtPoint:. But until #5165 lands, I’m not sure how we’d be able to reconcile the two methods’ queries. (One of them is limited to the tap point, the other to the entire viewport.)
@1ec5#5460 contains a potential fix for this issue. It does not attempt to handle the case of views that significantly change size after they are added. It does not require #5165 but will work well with it (assuming invisible images on the annotation model backed by views or some other solution, or course).
Activity
boundsj commentedon Jun 23, 2016
@1ec5 #5460 contains a potential fix for this issue. It does not attempt to handle the case of views that significantly change size after they are added. It does not require #5165 but will work well with it (assuming invisible images on the annotation model backed by views or some other solution, or course).
With this change:
Only view backed annotations
View + image backed annotations