1

I have a question regarding mapview annotations in ios. Is it possible to make an image popup by clicking on the annotation pin? If I use these?:

- (void)mapView:(MKMapView *)mapView didSelectAnnotationView:(MKAnnotationView *)view
{
    NSLog( @"selected annotation view" );

    [pictureView setImage:[UIImage imageNamed:@"clubs.png"]];
}

- (void)mapView:(MKMapView *)mapView didDeselectAnnotationView:(MKAnnotationView *)view
{  
    NSLog( @"deselected annotation view" );

    [pictureView setImage:[UIImage imageNamed:@"beer.png"]];
}

I have tried setting image, but the imageview doesnt display the image..? thanks in advance

Rob
  • 415,655
  • 72
  • 787
  • 1,044
  • If for iPad, you can use `UIPopoverController`. See http://stackoverflow.com/a/14619356/1271826. If for iPhone, there isn't a native popover controller, so you'd have to use some third party popover control or do something manually yourself. – Rob Sep 22 '13 at 18:29

1 Answers1

0

Take a look at creating a custom callout view. There are a number of 3rd party implementations that you can use / look at for inspiration. Perhaps start with this search of CocoaControls.

Wain
  • 118,658
  • 15
  • 128
  • 151