// 自定义的cell中粘贴下面代码,修改两个图片。
-(void)layoutSubviews
{
[super layoutSubviews];
for (UIControl *control in self.subviews){
if ([control isMemberOfClass:NSClassFromString(@"UITableViewCellEditControl")]){
for (UIView *v in control.subviews)
{
if ([v isKindOfClass: [UIImageView class]]) {
UIImageView *img=(UIImageView *)v;
if (self.selected) {
img.image=[UIImage imageNamed:@"XXX0.png"];
}else
{
img.image=[UIImage imageNamed:@"XXX1.png"];
}
}
}
}
}
}