Reputation: 174
I have an iPad app that displays a map with about 5000 POIs broken up into about 6 categories. Instead of the red pin, I am using my own annotation image. I use a different image for each category.
Everything seems to work fine, however when my client was testing it out on her device, she saw cases where some of the POIs were being displayed by the red pins instead of the custom image. She sent me a picture of the screen and I can see that some of the icons are correct, and some are red pins. All of the POIs on the screen shot she sent were in the same category and thus using the same image, so I know it isn't a case of a bad image.
Has anyone run into this before? Could it be some sort of memory issue? I haven't been able to reproduce it on my device.
Thanks.
Upvotes: 0
Views: 119
Reputation: 365
you have to make sure its like this MKAnnotationView not MKPinAnnotationView
static NSString* AnnotationIndentifer = @"AnnotationIdentifier";
MKAnnotationView* pinView = [[MKAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:AnnotationIndentifer];
Upvotes: 0
Reputation: 8304
You'd need to show us some code. I think the viewforAnnotation method would be the best place to start. Maybe thee are cases when it doesn't understand the category and doesn't give it your custom image. How is the categories set? Have you got any debugging code that proves they are set correctly on all annotations?
Upvotes: 1