Repository navigation
Conversation
|
@incanus, thanks for your PR! By analyzing the annotation information on this pull request, we identified @1ec5, @friedbunny and @boundsj to be potential reviewers |
Removed unused annotation image code from iosapp, now that bulk-added point annotations are backed by annotation views.
| annotation.coordinate = coordinate; | ||
| annotation.title = title; | ||
| annotation.subtitle = [NSString stringWithFormat:@"View: %i", useViews]; | ||
|
|
There was a problem hiding this comment.
Instead of using a magic string to detect a view-backed annotation, subclass MGLPointAnnotation and check whether it’s a kind of that subclass below. The class check is slightly more efficient than a string comparison and more self-documenting.
There was a problem hiding this comment.
Yeah, was thinking about that but trying to avoid overhead of a class. Probably a good idea, though.
|
Merged manually into Sorry, forgot the |
|
Forgot to force push this into the branch after rebase; remedied as of 4e61b2e. |
Background in 654f015#commitcomment-18366764.
We should have sprite-backed annotations as an option still for comparison to view-backed until such time that view-backed performance is equal or of negligible difference.
This more or less reverses 654f015, though it doesn't bring back
-mapView:didDeselectAnnotation:, of which I'm not sure what the point was—something about changing to pins if we don't have a sprite to reuse? Open to feedback here.Subjectively, since last being in this code, I am noticing a pretty marked performance decrease for annotation sprites, possibly related to z-ordering that I see happening during map rotation. Might be something else. I'm going to profile out of curiosity separately from this—this PR is just about the functionality. But these should be a lot faster.
/cc @1ec5 @boundsj