Loading core/java/android/widget/TextView.java +6 −0 Original line number Diff line number Diff line Loading @@ -11011,6 +11011,12 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener return true; case ID_COPY: // For link action mode in a non-selectable/non-focusable TextView, // make sure that we set the appropriate min/max. final int selStart = getSelectionStart(); final int selEnd = getSelectionEnd(); min = Math.max(0, Math.min(selStart, selEnd)); max = Math.max(0, Math.max(selStart, selEnd)); final ClipData copyData = ClipData.newPlainText(null, getTransformedText(min, max)); if (setPrimaryClip(copyData)) { stopTextActionMode(); Loading Loading
core/java/android/widget/TextView.java +6 −0 Original line number Diff line number Diff line Loading @@ -11011,6 +11011,12 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener return true; case ID_COPY: // For link action mode in a non-selectable/non-focusable TextView, // make sure that we set the appropriate min/max. final int selStart = getSelectionStart(); final int selEnd = getSelectionEnd(); min = Math.max(0, Math.min(selStart, selEnd)); max = Math.max(0, Math.max(selStart, selEnd)); final ClipData copyData = ClipData.newPlainText(null, getTransformedText(min, max)); if (setPrimaryClip(copyData)) { stopTextActionMode(); Loading