Skip to content

Commit 8466db0

Browse files
Sahil Ohrifacebook-github-bot
authored andcommitted
Summary: This change is a revert of [facebook#17927](facebook#17927) pull-request. The pull-request caused an issue with the keyboard covering the text field at the bottom of the scroll view. Reviewed By: shergin Differential Revision: D7246609 fbshipit-source-id: 149f825274c4fa79ab593f1bae3602667d16ddee
1 parent db061ea commit 8466db0

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

React/Views/ScrollView/RCTScrollView.m

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -575,9 +575,6 @@ - (void)scrollToOffset:(CGPoint)offset
575575
- (void)scrollToOffset:(CGPoint)offset animated:(BOOL)animated
576576
{
577577
if (!CGPointEqualToPoint(_scrollView.contentOffset, offset)) {
578-
CGFloat maxOffsetX = _scrollView.contentSize.width - _scrollView.bounds.size.width + _scrollView.contentInset.right;
579-
CGFloat maxOffsetY = _scrollView.contentSize.height - _scrollView.bounds.size.height + _scrollView.contentInset.bottom;
580-
offset = CGPointMake(MAX(0, MIN(maxOffsetX, offset.x)), MAX(0, MIN(maxOffsetY, offset.y)));
581578
// Ensure at least one scroll event will fire
582579
_allowNextScrollNoMatterWhat = YES;
583580
[_scrollView setContentOffset:offset animated:animated];

0 commit comments

Comments
 (0)