fix ios cursor bug when word.length==1 (#1168)

pull/1171/head
Pwiz 2 years ago committed by GitHub
parent d517847d8a
commit d62be3d12a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      lib/src/widgets/editor.dart

@ -1135,7 +1135,7 @@ class RenderEditor extends RenderEditableContainerBox
start: localWord.start + nodeOffset,
end: localWord.end + nodeOffset,
);
if (position.offset - word.start <= 1) {
if (position.offset - word.start <= 1 && word.end != position.offset) {
_handleSelectionChange(
TextSelection.collapsed(offset: word.start),
cause,

Loading…
Cancel
Save