Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions SWTableViewCell/PodFiles/SWTableViewCell.m
Original file line number Diff line number Diff line change
Expand Up @@ -757,6 +757,11 @@ - (void)scrollViewDidScroll:(UIScrollView *)scrollView
- (void)scrollViewDidEndDecelerating:(UIScrollView *)scrollView
{
[self updateCellState];
// if call "-(void)setRightUtilityButtons: WithButtonWidth:" to change the buttonWidth while scrollView is still scrolling, scrollView's contentOffset will be wrong.
CGPoint contentOffset = [self contentOffsetForCellState:_cellState];
if (!CGPointEqualToPoint(self.cellScrollView.contentOffset, contentOffset)) {
self.cellScrollView.contentOffset = contentOffset;
}

if (self.delegate && [self.delegate respondsToSelector:@selector(swipeableTableViewCellDidEndScrolling:)]) {
[self.delegate swipeableTableViewCellDidEndScrolling:self];
Expand Down