I'm using SWTableView for swipe left to give to the user more options, i added 4 elements and when i close the cell back , not all the cell return back to the place.
Please help]1
Asked
Active
Viewed 115 times
1

Yakir Sayada
- 171
- 1
- 11
1 Answers
1
Did you remember to set the cell's delegate? As described in the README?
- (UITableViewCell*)tableView:(UITableView*)tableView cellForRowAtIndexPath:(NSIndexPath*)indexPath
{
static NSString *cellIdentifier = @"MyCustomCell";
MyCustomTableViewCell *cell = (MyCustomTableViewCell *)[tableView dequeueReusableCellWithIdentifier:cellIdentifier
forIndexPath:indexPath];
cell.leftUtilityButtons = [self leftButtons];
cell.rightUtilityButtons = [self rightButtons];
cell.delegate = self;
cell.customLabel.text = @"Some Text";
cell.customImageView.image = [UIImage imageNamed:@"MyAwesomeTableCellImage"];
[cell setCellHeight:cell.frame.size.height];
return cell;
}

Subramani
- 477
- 2
- 14
-
1Add this [self hideUtilityButtonsAnimated:NO]; inside of SWTableViewCell.m at initialising place – Subramani Aug 01 '17 at 13:59
-
1if thats not work, Add this on cellForRowAtIndexPath if (!self.isThumbnailView) { for (SWTableViewCell *cell in [tableview visibleCells]) { [cell hideUtilityButtonsAnimated:YES]; } } – Subramani Aug 01 '17 at 14:00