diff --git a/SWTableViewCell/PodFiles/SWTableViewCell.m b/SWTableViewCell/PodFiles/SWTableViewCell.m index 1c6e57c..30e5a4d 100644 --- a/SWTableViewCell/PodFiles/SWTableViewCell.m +++ b/SWTableViewCell/PodFiles/SWTableViewCell.m @@ -655,18 +655,6 @@ - (void)scrollViewWillEndDragging:(UIScrollView *)scrollView withVelocity:(CGPoi [self.delegate swipeableTableViewCell:self scrollingToState:_cellState]; } - if (_cellState != kCellStateCenter) - { - if ([self.delegate respondsToSelector:@selector(swipeableTableViewCellShouldHideUtilityButtonsOnSwipe:)]) - { - for (SWTableViewCell *cell in [self.containingTableView visibleCells]) { - if (cell != self && [cell isKindOfClass:[SWTableViewCell class]] && [self.delegate swipeableTableViewCellShouldHideUtilityButtonsOnSwipe:cell]) { - [cell hideUtilityButtonsAnimated:YES]; - } - } - } - } - *targetContentOffset = [self contentOffsetForCellState:_cellState]; } @@ -742,6 +730,18 @@ -(void)scrollViewDidEndDragging:(UIScrollView *)scrollView willDecelerate:(BOOL) } +- (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView +{ + if ([self.delegate respondsToSelector:@selector(swipeableTableViewCellShouldHideUtilityButtonsOnSwipe:)]) + { + for (SWTableViewCell *cell in [self.containingTableView visibleCells]) { + if (cell != self && [cell isKindOfClass:[SWTableViewCell class]] && [self.delegate swipeableTableViewCellShouldHideUtilityButtonsOnSwipe:cell]) { + [cell hideUtilityButtonsAnimated:YES]; + } + } + } +} + #pragma mark - UIGestureRecognizerDelegate - (BOOL)gestureRecognizer:(UIGestureRecognizer *)gestureRecognizer shouldRecognizeSimultaneouslyWithGestureRecognizer:(UIGestureRecognizer *)otherGestureRecognizer