i add MKPinAnnotationView and setDragAble. my code is here
- (MKAnnotationView *)mapView:(MKMapView *)mapView viewForAnnotation:(id <MKAnnotation>)annotation {
MKPinAnnotationView *annotationView = [[MKPinAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:@"pin"];
[annotationView setDraggable:YES];
annotationView.pinColor = MKPinAnnotationColorPurple;
return [annotationView autorelease];
}
ok i can drag pin.
but one problem is it's not just one tap. always need second tap.
when i first tap pin is selected but can't drag. when i tap again it's available drag.
what's wrong? i want just one tap drag like "Map.app"
-[mapView selectAnnotation:]
in the delegate'smapView:didAddAnnotationViews:
method. Seems to work just as well. – Strident