gpt4 book ai didi

ios - UITableView setEditing 不显示删除按钮

转载 作者:塔克拉玛干 更新时间:2023-11-02 19:54:31 24 4
gpt4 key购买 nike

我使用下面的代码显示使表格变得可编辑,但表格 View 似乎没有在左侧显示删除按钮。为什么?

    - (void)viewListEditale:(NSNotification *)notification{

NSString *edited = [notification.object objectForKey:@"edit"];

if ([edited isEqualToString:@"N"]) {
[_tableView setEditing:NO animated:YES];
}else{
[_tableView setEditing:YES animated:YES];

}
}

enter image description here enter image description here

最佳答案

我遇到了和你一样的问题,上次忘记打电话了:

[super layoutSubviews]

当我打电话

-(void)layoutSubviews

在我的自定义 Cell 中。请检查您的代码。

关于ios - UITableView setEditing 不显示删除按钮,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35647660/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com