Cancel orphan toasts

This commit is contained in:
M66B 2022-05-29 13:57:54 +02:00
parent bfaad8333e
commit fd1013b6ad
5 changed files with 28 additions and 7 deletions

View File

@ -679,7 +679,10 @@ public class ActivityEML extends ActivityBase {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override

View File

@ -791,7 +791,10 @@ public class ActivitySetup extends ActivityBase implements FragmentManager.OnBac
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override

View File

@ -413,7 +413,10 @@ public class AdapterRule extends RecyclerView.Adapter<AdapterRule.ViewHolder> {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override

View File

@ -2397,7 +2397,10 @@ public class FragmentCompose extends FragmentBase {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override
@ -2474,7 +2477,10 @@ public class FragmentCompose extends FragmentBase {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override

View File

@ -498,7 +498,10 @@ public class FragmentContacts extends FragmentBase {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override
@ -597,7 +600,10 @@ public class FragmentContacts extends FragmentBase {
@Override
protected void onDestroyed(Bundle args) {
toast = null;
if (toast != null) {
toast.cancel();
toast = null;
}
}
@Override