我正在尝试为这样的两个视图制作动画:
CGAffineTransform transform = CGAffineTransformMakeRotation(M_PI_2);
CGRect rect = self.oneView.frame;
rect.origin.y = 10;
[UIView animateWithDuration:0.5 delay:0.0 options:UIViewAnimationOptionCurveLinear animations:^{
self.oneView.frame = rect;
self.buttonView.transform = transform;
} completion:^(BOOL finished) {
...
}];
但只有 buttonView 旋转了。OneView 保持不变。但如果我评论
//self.buttonView.transform = transform;
OneView 已移动。