我必须以这样的方式对几个按钮进行动画处理,使其看起来像是从下方旋转到屏幕上并设法做到了这一点。为了使解决方案起作用,我需要像这样更改 viewDidLoad 上的按钮方向:
for (UIButton* button in self.shareButtons) {
button.imageView.image = [UIImage imageWithCGImage:button.imageView.image.CGImage
scale:1.0 orientation: UIImageOrientationDownMirrored];
}
一切正常,但是当在按钮内捕获触摸时,它会取消此方向更改,并且由于动画导致按钮被“向下镜像”。
我该如何预防/避免它?
提前致谢。