【发布时间】:2014-03-03 14:06:26
【问题描述】:
我在 XIB 文件中有一个 UISegmentedControl。我已将它放置在 UIBarButtonItem 中,而后者又放置在 UIToolBar 中。我遇到的问题是 UISegmentedControl 没有响应触摸,即使我已连接到 IBAction 方法。知道可能是什么问题吗?
【问题讨论】:
标签: ios iphone uibarbuttonitem uisegmentedcontrol uitoolbar
我在 XIB 文件中有一个 UISegmentedControl。我已将它放置在 UIBarButtonItem 中,而后者又放置在 UIToolBar 中。我遇到的问题是 UISegmentedControl 没有响应触摸,即使我已连接到 IBAction 方法。知道可能是什么问题吗?
【问题讨论】:
标签: ios iphone uibarbuttonitem uisegmentedcontrol uitoolbar
我会检查以下项目:
IBAction 已连接UISegmentedControl
【讨论】:
确保将分段控件上的“.userInteractionEnabled”设置为“YES”。
【讨论】: