use panGestureRecognizer or touch events to drag and move an item ios <p>I am moving items in the view by touching them to the place where i leave it i am using touch events <code>touchesBegin</code> , <code>touchesMoved</code> , <code>touchesEnd</code><br> and in <code>touchesMoved</code> i move the item.frame to the new location and it works with me but then i found a code that use <code>panGestureRecognizer</code><br> and then i cant determine what to use </p> <p>the code to handle pan was </p> <pre><code>- (IBAction)handlePan:(UIPanGestureRecognizer *)recognizer { if (recognizer.state == UIGestureRecognizerStateBegan || recognizer.state == UIGestureRecognizerStateChanged) { CGPoint translation = [recognizer translationInView:self.superview]; CGPoint translatedCenter = CGPointMake(self.center.x + translation.x, self.center.y + translation.y); [self setCenter:translatedCenter]; [recognizer setTranslation:CGPointZero inView:self]; } </code></pre> <p><strong>given that i need the exact coordinates of the point i am touching</strong> </p>