iphone - 区分 didSelectRowAtIndexPath 和accessoryButtonTappedForRowWithIndexPath

标签 iphone cocoa-touch uitableview

我已经实现了 didSelectRowAtIndexPath 和accessoryButtonTappedForRowWithIndexPath 似乎永远不会触发。但是,didSelectRowAtIndexPath 始终会触发,即使我单击附件也是如此。这两个不应该是排他的吗?

最佳答案

-[UITableViewDelegateaccessoryButtonTappedForRowWithIndexPath:]仅在单元格的accessoryType设置为UITableViewCellAccessoryDe​​tailDisclosureButton时调用。

关于iphone - 区分 didSelectRowAtIndexPath 和accessoryButtonTappedForRowWithIndexPath,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1943183/

相关文章:

ios - 在 UITableViewCell 中进入编辑模式时隐藏 UITableViewCells(类似于联系人应用程序)

iphone - 更改所选单元格的背景颜色?

iphone - 一起使用 UINavigationController 和标签栏

iphone - 显示 UIActivityIndi​​cator x 秒

ios - 使用核心动画在屏幕上移动 UIImage

objective-c - 键值编码及其脚本能力

ios - 创建滑动以显示 iOS 7 的按钮,使用清晰的背景色

ios - interface builder : make the view the same size as the iphone, 确切知道要添加什么约束?

iphone - 没有已知的选择器'JSONValue'实例方法

iphone - 自定义 UIBarButtonItem 的事件区域更小