【发布时间】:2015-05-29 12:21:28
【问题描述】:
我在
中创建了UITableViewRowAction的实例
-(NSArray *)tableView:(UITableView *)tableView editActionsForRowAtIndexPath:(NSIndexPath *)indexPath
当触发此行操作时,我有一个处理程序块:
handler:^(UITableViewRowAction *action, NSIndexPath *indexPath)
您有一个可以使用的行操作参数,因此您不会创建保留周期,并且您有一个索引路径。我尝试像这样设置新行操作的backgroundColor:
[action setBackgroundColor:[UIColor greenColor]];
但这并没有改变任何东西。我还在行操作的按钮对象上尝试了setNeedsDisplay,但没有任何运气。
知道如何在行操作仍然可见的情况下更改 backgroundColor 吗?谢谢
- xCoder
【问题讨论】:
-
在此处发布您的
editActionsForRowAtIndexPath工具
标签: ios objective-c uitableview uitableviewrowaction