|
|
@ -959,6 +959,7 @@ public class StyleHelper {
|
|
|
|
static void markAsInserted(Editable text, int start, int end) {
|
|
|
|
static void markAsInserted(Editable text, int start, int end) {
|
|
|
|
for (InsertedSpan span : text.getSpans(0, text.length(), InsertedSpan.class))
|
|
|
|
for (InsertedSpan span : text.getSpans(0, text.length(), InsertedSpan.class))
|
|
|
|
text.removeSpan(span);
|
|
|
|
text.removeSpan(span);
|
|
|
|
|
|
|
|
if (start >= 0 && start < end && end <= text.length())
|
|
|
|
text.setSpan(new InsertedSpan(), start, end, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
|
|
|
text.setSpan(new InsertedSpan(), start, end, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|