From 33fe87338315845b46e8284cd7876e448d362d10 Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 18 Oct 2018 11:13:11 +0000 Subject: [PATCH] Fixed flickering --- app/src/main/java/eu/faircode/email/ActivityView.java | 3 ++- app/src/main/java/eu/faircode/email/FragmentMessages.java | 3 --- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/eu/faircode/email/ActivityView.java b/app/src/main/java/eu/faircode/email/ActivityView.java index e56850f7..22c151de 100644 --- a/app/src/main/java/eu/faircode/email/ActivityView.java +++ b/app/src/main/java/eu/faircode/email/ActivityView.java @@ -303,7 +303,6 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB intent.setAction(null); setIntent(intent); - getSupportFragmentManager().popBackStack("unified", 0); intent.putExtra("thread", action.split(":", 2)[1]); onViewThread(intent); } @@ -767,6 +766,8 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB } private void onViewThread(Intent intent) { + getFragmentManager().popBackStack("thread", FragmentManager.POP_BACK_STACK_INCLUSIVE); + Bundle args = new Bundle(); args.putLong("account", intent.getLongExtra("account", -1)); args.putString("thread", intent.getStringExtra("thread")); diff --git a/app/src/main/java/eu/faircode/email/FragmentMessages.java b/app/src/main/java/eu/faircode/email/FragmentMessages.java index 84ac25bf..ba2ab74e 100644 --- a/app/src/main/java/eu/faircode/email/FragmentMessages.java +++ b/app/src/main/java/eu/faircode/email/FragmentMessages.java @@ -52,7 +52,6 @@ import androidx.annotation.NonNull; import androidx.annotation.Nullable; import androidx.appcompat.widget.SearchView; import androidx.constraintlayout.widget.Group; -import androidx.fragment.app.FragmentManager; import androidx.fragment.app.FragmentTransaction; import androidx.lifecycle.Lifecycle; import androidx.lifecycle.LiveData; @@ -475,8 +474,6 @@ public class FragmentMessages extends FragmentEx { View.OnClickListener navigate = new View.OnClickListener() { @Override public void onClick(View v) { - getFragmentManager().popBackStack("thread", FragmentManager.POP_BACK_STACK_INCLUSIVE); - LocalBroadcastManager lbm = LocalBroadcastManager.getInstance(getContext()); lbm.sendBroadcast( new Intent(ActivityView.ACTION_VIEW_THREAD)