Overview (Edited)
I have UITableView, when I swipe, the delete button appears, when I touch else where, the delete button just disappears without any animation.
With Accessory
Without Accessory
Question
On iOS 6 this "bug" still exists. There are 2 ways to workaround this problem:
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
//[...]
cell.accessoryView = [UIView new];
//[...]
}
- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
{
cell.accessoryView = [UIView new];
}
This way when "remove row" is canceled, the button disappears with animation.
If you are not using the cell.textlabel property, try to set it to something and then hide it.
cell.textlabel.text = @"something";
Cell.textlabel.hidden = YES;
It should work
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With