i'd like to drag the image "finga" inside a region height of 320. this goes off screen:
- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
UITouch *touch = [[event allTouches] anyObject];
CGPoint location = [touch locationInView:self.view];
if (CGRectContainsPoint(finga.frame, location)){
CGPoint yLocation = CGPointMake(finga.center.x,location.y);
finga.center = yLocation;
}
}
how to define the region? thanx