Hi,
I have modyfied the Touches sample Code:
Excluded (void)touchesMoved

NSSet *)touches withEvent

UIEvent *)event
and the squares are in fixed position and the animation works. It was my intention.
If I touch inside the square it grows, but if I pull my finger to the background it does't shrinks and the dispatchTouchEndEvent does't works. Here is the dispatch Code:
Code:
-(void) dispatchTouchEndEvent:(UIView *)theView toPosition:(CGPoint)position
{
// Check to see which view, or views, the point is in and then animate to that position.
if (CGRectContainsPoint([firstPieceView frame], position)) {
[self animateView:firstPieceView toPosition: position];
}
if (CGRectContainsPoint([secondPieceView frame], position)) {
[self animateView:secondPieceView toPosition: position];
}
if (CGRectContainsPoint([thirdPieceView frame], position)) {
[self animateView:thirdPieceView toPosition: position];
}
Can somebody help me?