我想让 slider 缓慢地设置值,为此我正在使用这段代码
[UIView animateWithDuration:2.0 animations:^{
[self.slider setValue:(float)val];
}];
但这行不通。 请帮帮我。
最佳答案
改用[self.slider setValue:(float)val animated:YES];
。
关于ios - UIView animateWithDuration 不适用于 UISlider,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20539913/