Prevent crash

This commit is contained in:
M66B
2021-09-28 21:15:46 +02:00
parent d69cdbb506
commit 3f228fc559
12 changed files with 57 additions and 7 deletions

View File

@@ -579,6 +579,8 @@ public class FragmentCompose extends FragmentBase {
getMainHandler().postDelayed(new Runnable() {
@Override
public void run() {
if (!getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED))
return;
if (styling != selection) {
styling = selection;
media_bar.getMenu().clear();
@@ -1688,6 +1690,8 @@ public class FragmentCompose extends FragmentBase {
getMainHandler().post(new Runnable() {
@Override
public void run() {
if (!getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED))
return;
if (grpAddresses.getVisibility() == View.GONE)
etSubject.requestFocus();
else
@@ -6255,6 +6259,9 @@ public class FragmentCompose extends FragmentBase {
@Override
public void run() {
try {
if (!getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED))
return;
if (target instanceof EditText) {
EditText et = (EditText) target;
int len = et.length();