You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 24, 2019. It is now read-only.
I'm currently using SAMTextView in a full-screen modal. Whenever the keyboard appears or disappears, I animate the updated constraint. While the animation is taking the place, the placeholder text shrinks while the resize is taking place but then is redrawn after the animation is complete. I've attached a snippet of code which causes the issue.
- (void)keyboardWillShow:(NSNotification *)note {
NSDictionary *userInfo = [note userInfo];
CGRect keyboardFrame = [userInfo[UIKeyboardFrameEndUserInfoKey] CGRectValue];
// Check if the constraint is the same as what it is about to be set to, and abort if it is.
if (self.descriptionBottomConstraint.constant == -(keyboardFrame.size.height)) {
return;
}
double animationDuration = [((NSNumber *)userInfo[UIKeyboardAnimationDurationUserInfoKey]) doubleValue];
[self.view layoutIfNeeded];
self.descriptionBottomConstraint.constant = -(keyboardFrame.size.height);
[UIView animateWithDuration:animationDuration animations:^{
[self.view layoutIfNeeded];
}];
}
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I'm currently using
SAMTextView
in a full-screen modal. Whenever the keyboard appears or disappears, I animate the updated constraint. While the animation is taking the place, the placeholder text shrinks while the resize is taking place but then is redrawn after the animation is complete. I've attached a snippet of code which causes the issue.The text was updated successfully, but these errors were encountered: