开发者

How to create a TableView without a deletion control?

When a table view goes into editing mode, it shows the delete controls on the left, and also reordering controls on the right.

I have no need for deleting the rows, hence I return UITableViewCellEditingStyleNone for -(UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPa开发者_StackOverflow社区th.

But doing so merely hides the red delete control. The table row will still be indented when I go into editing mode. Is it possible to hide the deletion control completely?


You need to also return NO for – tableView:shouldIndentWhileEditingRowAtIndexPath:.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜