谁知道UITable单元格减号按钮的背景图片怎么改,
我需要更改此按钮 类似于
因为如果你在 iOS6 和 iOS7 之间切换,这个按钮就会改变。
Best Answer-推荐答案 strong>
希望对你有帮助
- (void)willTransitionToStateUITableViewCellStateMask)state
{
[super willTransitionToState:state];
if ((state & UITableViewCellStateShowingDeleteConfirmationMask) == UITableViewCellStateShowingDeleteConfirmationMask)
{
for (UIView *subview in self.subviews)
{
if ([NSStringFromClass([subview class]) isEqualToString"UITableViewCellDeleteConfirmationControl"])
{
UIImageView *deleteBtn = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 64, 33)];
[deleteBtn setImage:[UIImage imageNamed"deleteNewImg.png"]];
[[subview.subviews objectAtIndex:0] addSubview:deleteBtn];
}
}
}
}
关于ios - 更改 UITableViewCellEditingStyleDelete 的图像,我们在Stack Overflow上找到一个类似的问题:
https://stackoverflow.com/questions/22916301/
|