iOS: fix when list is in Refreshable, it may not be able to respond to the sliding gesture in time when the list is swiped quickly.
This commit is contained in:
parent
978e33e8c5
commit
b1c4ccd944
@ -112,7 +112,12 @@ - (void)scrollViewDidScroll:(UIScrollView *)scrollView {
|
||||
} else if (scrollView.contentOffset.y + scrollView.height > scrollView.contentSize.height) {
|
||||
if ([self.contentView isKindOfClass:UIScrollView.class]
|
||||
&& ((UIScrollView *) self.contentView).contentOffset.y + self.contentView.height < ((UIScrollView *) self.contentView).contentSize.height) {
|
||||
scrollView.contentOffset = (CGPoint) {0, scrollView.contentSize.height - scrollView.height};
|
||||
self.bounces = NO;
|
||||
[UIView animateWithDuration:0.2f animations:^{
|
||||
scrollView.contentOffset = (CGPoint) {0, scrollView.contentSize.height - scrollView.height};
|
||||
} completion:^(BOOL finished) {
|
||||
self.bounces = YES;
|
||||
}];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user