【发布时间】:2013-03-29 12:37:52
【问题描述】:
我在 UITable 视图中有问题。我正在使用这样的分组样式的 UITableView 和自定义单元格视图
我的问题是在编辑我的表格视图时,它的显示如下
但我需要在编辑这样的表格视图时隐藏缩略图
我在编辑表格视图[cell.imageviews setHidden:YES] 时尝试过,但它不起作用请任何人帮助我,如果问题已经在 Stack-overflow 中,请给我参考链接或任何其他建议?
** 更新**
这是我的 cellForRowAtIndexPath 代码
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
static NSString *CustomCellidentifier = @"IListCell";
IListCell *cell = (IListCell *)[tableView dequeueReusableCellWithIdentifier:CustomCellidentifier];
if(cell == nil) {
NSArray *nib = [[NSBundle mainBundle] loadNibNamed:@"IListCell" owner:self options:nil];
cell = [nib objectAtIndex:0];
}
if (self.tableview.isEditing) {
[cell.photoImageView setHidden:YES];
}
cell.titleTextField.text=[NSString stringWithFormat:@"%@",[artAlbumList objectAtIndex:indexPath.row]];
return cell;
}
IListCell 是 UITableViewCelll 的子类,使用 XIB 文件创建的自定义单元这是我的 xib 文件
【问题讨论】:
-
以该方法发布您的代码。
-
邮政编码:IListCell
标签: iphone uitableview