1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-25 17:27:00 +00:00

Show account folder rule

This commit is contained in:
M66B 2023-03-31 09:03:53 +02:00
parent 61ad1cc974
commit cafb7a5b20

View file

@ -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<EntityIdentity> identities;
List<EntityAnswer> answers;