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

Commit e9d561e6 authored by Justin Ghan's avatar Justin Ghan
Browse files

Fix CursorAnchorInfo insertion marker location when cursor is clamped

Bug: 301135322
Test: tested manually
Change-Id: I6d2d43330fff57115c09222836d2475dbd1444ee
parent 1b2195f6
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -14051,7 +14051,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener
                            selectionStart, OffsetMapping.MAP_STRATEGY_CURSOR);
                    final int line = layout.getLineForOffset(offsetTransformed);
                    final float insertionMarkerX =
                            layout.getPrimaryHorizontal(offsetTransformed)
                            layout.getPrimaryHorizontal(
                                            offsetTransformed, layout.shouldClampCursor(line))
                                    + viewportToContentHorizontalOffset;
                    final float insertionMarkerTop = layout.getLineTop(line)
                            + viewportToContentVerticalOffset;