gpt4 book ai didi

objective-c - UIView animateWithDuration 不适用于 iPhone X 模拟器和设备

转载 作者:搜寻专家 更新时间:2023-10-30 20:27:45 24 4
gpt4 key购买 nike

UIView animateWithDuration 在 iPhone X 和模拟器中不工作。当模拟器缩小时,它对模拟器工作正常,但当模拟器放大时,它会卡住。

注意:- 对于所有其他设备,它运行良好,没有任何问题。

这是我的代码:-

[UIView animateWithDuration:0 animations:^{
viewBoundry.transform = CGAffineTransformMakeRotation(radians(Boundedangele));
[objClip updateAngle:Boundedangele];
} completion:^(BOOL finished) {
}];

谢谢。

最佳答案

检查 UIView 中可能受动画影响的约束。

您的动画可能会破坏仅与 iPhone X 布局相关的约束,因此永远不会调用完成 block 。

关于objective-c - UIView animateWithDuration 不适用于 iPhone X 模拟器和设备,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48075886/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com