ios - 关闭UIButton闪烁动画

标签 ios xcode uibutton

我想关闭UIButton闪烁动画,我尝试使用:

button.highlighted = NO;
[button setHighlighted:NO];

(但是一直没有关闭UIButton闪烁动画,没有反应..)

我尝试另一个:

[button setEnabled:NO];

(按钮闪烁关闭,但我的按钮变成白色。)

请大家给我一些建议,谢谢!!

最佳答案

根据需要使用其中任何一个-

  1. 这将禁用按钮 -

    button.userInteractionEnabled = NO;
    
  2. 在 xib 文件中 - 您可以取消选中“突出显示调整图像”

关于ios - 关闭UIButton闪烁动画,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10649903/

相关文章:

iphone - 一个代码库,但 iOS 应用程序的图像和外部数据不同

ios - 将 subview Controller 链接到 Storyboard中的父 View Controller

swift - 为 CollectionView 添加边框

ios - 输入邮政编码开关查看 Controller (如果在 Parse 中找到)(Swift 和 XCode)

ios - "Building for iOS, but the embedded framework ' xxx.framework ' was built for iOS + iOS Simulator"

iOS/swift/ Storyboard : Add PageViewController using only *part* of screen?

ios - 单击第一个按钮时启用下一个按钮

iphone - 如何在两个 UIButton 选择器之间切换

iphone - 如何检测进入 UIButton 框架的触摸?

html - 对象在 iphone 中没有占据全宽