Albatrox
Albatrox

Reputation: 63

Drag to rotate in iPhone-app

I'm trying to drag a UIImageView according to an anchorPoint but the whole image move. In fact i have a view for my app settings and one parameter is setted with a dial (with a hand/needle(?)). I'd like the rotation center of the needle/hand doesn't move when i'm dragging it.

Thanks for your future answers.

Upvotes: 0

Views: 659

Answers (1)

amattn
amattn

Reputation: 10065

You will have to set up a transform rotation on the layer of your needle.

The perfect sample code for you to look at is the Metronome app that Apple provides. This will be very similar to what you want to do.

Upvotes: 1

Related Questions