From cafb7a5b205046fb50e098d2a5d13ff301fccf46 Mon Sep 17 00:00:00 2001 From: M66B Date: Fri, 31 Mar 2023 09:03:53 +0200 Subject: [PATCH] Show account folder rule --- app/src/main/java/eu/faircode/email/FragmentRule.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/eu/faircode/email/FragmentRule.java b/app/src/main/java/eu/faircode/email/FragmentRule.java index 9b30cc6f0b..d876df52b1 100644 --- a/app/src/main/java/eu/faircode/email/FragmentRule.java +++ b/app/src/main/java/eu/faircode/email/FragmentRule.java @@ -835,6 +835,7 @@ public class FragmentRule extends FragmentBase { RefData data = new RefData(); DB db = DB.getInstance(context); + data.account = db.account().getAccount(aid); data.folder = db.folder().getFolder(fid); data.identities = db.identity().getSynchronizingIdentities(aid); data.answers = db.answer().getAnswers(false); @@ -844,7 +845,9 @@ public class FragmentRule extends FragmentBase { @Override protected void onExecuted(Bundle args, RefData data) { - tvFolder.setText(data.folder.getDisplayName(getContext())); + tvFolder.setText(String.format("%s:%s", + data.account == null ? "" : data.account.name, + data.folder.getDisplayName(getContext()))); adapterIdentity.clear(); adapterIdentity.addAll(data.identities); @@ -1673,6 +1676,7 @@ public class FragmentRule extends FragmentBase { } private static class RefData { + EntityAccount account; EntityFolder folder; List identities; List answers;