session-android/src/org/thoughtcrime/securesms/contactshare/SimpleTextWatcher.java
Greyson Parrelli e1f8e87327 Fix log submission OOM, improve log scrolling.
We were getting a TransactionTooLargeException when giving an
EditText a very large (1.5MB+) text block. This has been resolved
by switching to a RecyclerView to show the text line-by-line. As a
side-effect, this improves scroll performance on lower-end devices.

Also, I added a button to jump to the bottom of the log because I
really wanted one :)

Fixes #8124
2018-08-20 01:24:36 -07:00

21 lines
521 B
Java

package org.thoughtcrime.securesms.contactshare;
import android.text.Editable;
import android.text.TextWatcher;
public abstract class SimpleTextWatcher implements TextWatcher {
@Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) { }
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
onTextChanged(s.toString());
}
@Override
public void afterTextChanged(Editable s) { }
public abstract void onTextChanged(String text);
}