简体   繁体   中英

How to drag annotation pin in ios like in Android?

In my application I am able to drag annotation from one point to other, but I want make the dragging as in Android ie when we select the annotation it will move a bit up and once the dragging ends it will come to its actual end point position by moving down.

I want to get the same kind of animation feel in iOS, can anybody suggest me how to achieve this.

yes you can do it ...

MKPinkAnnotationView *pin = [[MKPinAnnotationView alloc] initWithAnnotation:annotation reuseIdentifier:[annotation title]];

pin.animatesDrop = YES; pin.canShowCallout = YES; pin.draggable = YES;`

continue your coding from there forth

or you can go threw this link

https://github.com/yury/TiMobile-map-pin-drag-and-drop

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM