Fix KBAICommentInputView弹出位置

This commit is contained in:
2026-02-25 17:13:25 +08:00
parent 851c0d9531
commit 92ca5c6180
3 changed files with 156 additions and 8 deletions

View File

@@ -92,7 +92,9 @@
}
- (void)showKeyboard {
[self.textField becomeFirstResponder];
BOOL before = self.textField.isFirstResponder;
BOOL become = [self.textField becomeFirstResponder];
NSLog(@"[KBAICommentInputView] showKeyboard before=%d become=%d after=%d", before, become, self.textField.isFirstResponder);
}
#pragma mark - Actions
@@ -129,11 +131,17 @@
}
- (BOOL)textFieldShouldBeginEditing:(UITextField *)textField {
NSLog(@"[KBAICommentInputView] textFieldShouldBeginEditing");
[self updatePlaceholderVisibility];
return YES;
}
- (void)textFieldDidBeginEditing:(UITextField *)textField {
NSLog(@"[KBAICommentInputView] textFieldDidBeginEditing firstResponder=%d", textField.isFirstResponder);
}
- (void)textFieldDidEndEditing:(UITextField *)textField {
NSLog(@"[KBAICommentInputView] textFieldDidEndEditing");
[self updatePlaceholderVisibility];
}