From 3a0e57579e5125cd3b6fbeb562fd94c934b4d678 Mon Sep 17 00:00:00 2001 From: M66B Date: Mon, 27 Sep 2021 18:57:39 +0200 Subject: [PATCH] Clean setup task --- app/src/main/java/eu/faircode/email/ActivityError.java | 4 ++-- app/src/main/java/eu/faircode/email/ActivityMain.java | 2 +- app/src/main/java/eu/faircode/email/ActivityView.java | 8 ++++---- app/src/main/java/eu/faircode/email/AdapterFolder.java | 2 +- app/src/main/java/eu/faircode/email/AdapterMessage.java | 2 +- app/src/main/java/eu/faircode/email/FragmentAccounts.java | 2 +- app/src/main/java/eu/faircode/email/FragmentCompose.java | 8 ++++---- .../java/eu/faircode/email/FragmentDialogForwardRaw.java | 2 +- .../java/eu/faircode/email/FragmentDialogIdentity.java | 4 ++-- .../java/eu/faircode/email/FragmentDialogOpenLink.java | 2 +- app/src/main/java/eu/faircode/email/FragmentFolders.java | 2 +- app/src/main/java/eu/faircode/email/FragmentMessages.java | 8 ++++---- app/src/main/java/eu/faircode/email/FragmentPro.java | 2 +- .../main/java/eu/faircode/email/ServicePowerControl.java | 2 +- 14 files changed, 25 insertions(+), 25 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/ActivityError.java b/app/src/main/java/eu/faircode/email/ActivityError.java index b28fdd6c2c..ef3ffa1a79 100644 --- a/app/src/main/java/eu/faircode/email/ActivityError.java +++ b/app/src/main/java/eu/faircode/email/ActivityError.java @@ -114,7 +114,7 @@ public class ActivityError extends ActivityBase { @Override protected void onExecuted(Bundle args, Void data) { startActivity(new Intent(ActivityError.this, ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK) .putExtra("target", "accounts") .putExtra("id", account) .putExtra("protocol", protocol)); @@ -134,7 +134,7 @@ public class ActivityError extends ActivityBase { @Override public void onClick(View v) { v.getContext().startActivity(new Intent(v.getContext(), ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK) .putExtra("target", "accounts") .putExtra("id", account) .putExtra("protocol", protocol)); diff --git a/app/src/main/java/eu/faircode/email/ActivityMain.java b/app/src/main/java/eu/faircode/email/ActivityMain.java index 461eb21132..95ca230622 100644 --- a/app/src/main/java/eu/faircode/email/ActivityMain.java +++ b/app/src/main/java/eu/faircode/email/ActivityMain.java @@ -208,7 +208,7 @@ public class ActivityMain extends ActivityBase implements FragmentManager.OnBack }, SERVICE_START_DELAY); } else { Intent setup = new Intent(ActivityMain.this, ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK); startActivity(setup, options); } diff --git a/app/src/main/java/eu/faircode/email/ActivityView.java b/app/src/main/java/eu/faircode/email/ActivityView.java index 8cb70661b3..681b9aa5a9 100644 --- a/app/src/main/java/eu/faircode/email/ActivityView.java +++ b/app/src/main/java/eu/faircode/email/ActivityView.java @@ -386,7 +386,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB public boolean onMenuItemClick(MenuItem item) { String tab = FragmentOptions.TAB_LABELS.get(item.getOrder()); startActivity(new Intent(ActivityView.this, ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK) .putExtra("tab", tab)); return true; } @@ -400,7 +400,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB @Override public boolean onLongClick(View view) { startActivity(new Intent(ActivityView.this, ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)); + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK)); return true; } }); @@ -1395,7 +1395,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB Intent manage = new Intent(ActivityView.this, ActivitySetup.class) .setAction("misc") - .setFlags(Intent.FLAG_ACTIVITY_NEW_TASK) + .setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK) .putExtra("tab", "misc"); PendingIntent piManage = PendingIntentCompat.getActivity( ActivityView.this, ActivitySetup.PI_MISC, manage, PendingIntent.FLAG_UPDATE_CURRENT); @@ -1635,7 +1635,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB private void onMenuSetup() { startActivity(new Intent(ActivityView.this, ActivitySetup.class) - .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)); + .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK)); } private void onMenuLegend() { diff --git a/app/src/main/java/eu/faircode/email/AdapterFolder.java b/app/src/main/java/eu/faircode/email/AdapterFolder.java index c11e2700c6..3520dc9d1a 100644 --- a/app/src/main/java/eu/faircode/email/AdapterFolder.java +++ b/app/src/main/java/eu/faircode/email/AdapterFolder.java @@ -769,7 +769,7 @@ public class AdapterFolder extends RecyclerView.Adapter