Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d16f1e8f authored by Yoshiki Iguchi's avatar Yoshiki Iguchi Committed by android-build-merger
Browse files

Fix crash on calling removeSelection with showing selection handlers

am: 9582e151

* commit '9582e151':
  Fix crash on calling removeSelection with showing selection handlers
parents d34879ce 9582e151
Loading
Loading
Loading
Loading
+10 −2
Original line number Diff line number Diff line
@@ -4253,10 +4253,14 @@ public class Editor {
            positionAtCursorOffset(offset, false);
        }

        /**
         * @param offset Cursor offset. Must be in [-1, length].
         * @param parentScrolled If the parent has been scrolled or not.
         */
        @Override
        protected void positionAtCursorOffset(int offset, boolean parentScrolled) {
            super.positionAtCursorOffset(offset, parentScrolled);
            mInWord = !getWordIteratorWithText().isBoundary(offset);
            mInWord = (offset != -1) && !getWordIteratorWithText().isBoundary(offset);
        }

        @Override
@@ -4489,10 +4493,14 @@ public class Editor {
            positionAtCursorOffset(offset, false);
        }

        /**
         * @param offset Cursor offset. Must be in [-1, length].
         * @param parentScrolled If the parent has been scrolled or not.
         */
        @Override
        protected void positionAtCursorOffset(int offset, boolean parentScrolled) {
            super.positionAtCursorOffset(offset, parentScrolled);
            mInWord = !getWordIteratorWithText().isBoundary(offset);
            mInWord = (offset != -1) && !getWordIteratorWithText().isBoundary(offset);
        }

        @Override