在我的iphone应用程序中,我有一个处于编辑模式的UITableView,用户只允许对行进行重新排序,而不授予删除权限.
那么有没有什么方法可以在TableView中隐藏"-"红色按钮呢.请告诉我.
谢谢
在我的iphone应用程序中,我有一个处于编辑模式的UITableView,用户只允许对行进行重新排序,而不授予删除权限.
那么有没有什么方法可以在TableView中隐藏"-"红色按钮呢.请告诉我.
谢谢
这是我的完整解决方案,单元格没有缩进(0左对齐)!
- (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath {
return YES;
}
- (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath{
return UITableViewCellEditingStyleNone;
}
- (BOOL)tableView:(UITableView *)tableview shouldIndentWhileEditingRowAtIndexPath:(NSIndexPath *)indexPath {
return NO;
}
- (BOOL)tableView:(UITableView *)tableview canMoveRowAtIndexPath:(NSIndexPath *)indexPath {
return YES;
}