I have a View in which there are 3 buttons as subview. the view rotates 360 degree, so as the button rotates the problem is when i click the button, as the frame of a button does not changes the position so it fires the wrong touch event.
CABasicAnimation *fullRotation1;
CGFloat duration1 = 8.0;
float repeatCount1 = 0;
fullRotation1 = [CABasicAnimation animationWithKeyPath:@"transform.rotation"];
fullRotation1.fromValue = [NSNumber numberWithFloat:0];
fullRotation1.toValue = [NSNumber numberWithFloat:((360 * M_PI) / 180)];
fullRotation1.duration = duration1;
if (repeatCount1 == 0)
fullRotation1.repeatCount = MAXFLOAT;
else
fullRotation1.repeatCount = repeatCount1;
[imgrotatebutton.layer addAnimation:fullRotation1 forKey:@"360"];
how should i attain button frame to be moved along with layer
Thanks