CABasicAnimationを使用して画像を移動していますが、タッチイベントのrectが古い位置のままであることに気付きました-rectを更新して、間違った場所に登録されないようにするにはどうすればよいですか?
CABasicAnimation *theAnimation;
theAnimation=[CABasicAnimation animationWithKeyPath:@"transform.translation.x"];
theAnimation.duration=0.3;
theAnimation.repeatCount=0;
theAnimation.fillMode = kCAFillModeForwards;
theAnimation.removedOnCompletion = NO;
theAnimation.autoreverses=NO;
theAnimation.fromValue=[NSNumber numberWithFloat:0];
theAnimation.toValue=[NSNumber numberWithFloat:-rect.size.width*0.9];
[self.layer addAnimation:theAnimation forKey:@"animateLayer"];