filter the candidate while inputing
This commit is contained in:
parent
b18bec6899
commit
5a9b55c75b
@ -227,6 +227,8 @@ - (BOOL)textViewShouldEndEditing:(UITextView *)textView {
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)textViewDidChange:(UITextView *)textView {
|
- (void)textViewDidChange:(UITextView *)textView {
|
||||||
|
if (textView.markedTextRange) return;
|
||||||
|
|
||||||
if (self.maxLength) {
|
if (self.maxLength) {
|
||||||
UITextRange *selectedRange = [textView markedTextRange];
|
UITextRange *selectedRange = [textView markedTextRange];
|
||||||
UITextPosition *pos = [textView positionFromPosition:selectedRange.start offset:0];
|
UITextPosition *pos = [textView positionFromPosition:selectedRange.start offset:0];
|
||||||
|
Reference in New Issue
Block a user