将UITableView放入编辑模式而不移动TextLabel? [英] Put a UITableView into editing mode without moving the TextLabel?

查看:76
本文介绍了将UITableView放入编辑模式而不移动TextLabel?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个可排序的UITableView,但就是这样。现在,我所有的单元格设置为UITableViewCellEditingStyleNone,但这仍然将单元格的TextLabel向右移动40像素。

I've got a UITableView that is sortable, but that's it. Right now, I have all the cells set to UITableViewCellEditingStyleNone, but this still moves the TextLabel of the cell over to the right by 40 pixels. Is there anyway to get edit mode, and the sort icon at the right, without shifting the TextLabel over?

推荐答案

你想要什么?在委托中是 - tableView:shouldIndentWhileEditingRowAtIndexPath:。有返回 NO

What you want is - tableView: shouldIndentWhileEditingRowAtIndexPath: in the delegate. Have that return NO.

这篇关于将UITableView放入编辑模式而不移动TextLabel?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆