Skip to content

Commit 3ce0f7b

Browse files
author
Ignacio Romero Zurbuchen
committed
Fixes the auto-completion form being busted. This is a regression from the previous commit.
1 parent 62a6000 commit 3ce0f7b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Source/SLKTextViewController.m

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1196,6 +1196,7 @@ - (void)slk_adjustContentConfigurationIfNeeded
11961196
// scrollView correctly to its top edge.
11971197
if (self.inverted) {
11981198
contentInset.bottom = [self slk_topBarsHeight];
1199+
contentInset.top = contentInset.bottom > 0.0 ? 0.0 : contentInset.top;
11991200
}
12001201
else {
12011202
contentInset.bottom = 0.0;
@@ -2077,7 +2078,7 @@ - (void)slk_setupViewConstraints
20772078
@"textInputbar": self.textInputbar,
20782079
};
20792080

2080-
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|[scrollView(0@750)][autoCompletionView(0@750)][typingIndicatorView(0)]-0-[textInputbar(==0)]-0-|" options:0 metrics:nil views:views]];
2081+
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"V:|[scrollView(0@750)][autoCompletionView(0@750)][typingIndicatorView(0)]-0@999-[textInputbar(0)]-0-|" options:0 metrics:nil views:views]];
20812082
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|[scrollView]|" options:0 metrics:nil views:views]];
20822083
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|[autoCompletionView]|" options:0 metrics:nil views:views]];
20832084
[self.view addConstraints:[NSLayoutConstraint constraintsWithVisualFormat:@"H:|[typingIndicatorView]|" options:0 metrics:nil views:views]];
@@ -2090,7 +2091,6 @@ - (void)slk_setupViewConstraints
20902091
self.keyboardHC = [self.view slk_constraintForAttribute:NSLayoutAttributeBottom firstItem:self.view secondItem:self.textInputbar];
20912092

20922093
self.textInputbarHC.constant = self.textInputbar.minimumInputbarHeight;
2093-
20942094
self.scrollViewHC.constant = [self slk_appropriateScrollViewHeight];
20952095

20962096
if (self.textInputbar.isEditing) {

0 commit comments

Comments
 (0)