Show send state/errors

This commit is contained in:
M66B
2018-08-15 11:26:59 +00:00
parent 92fc1349f0
commit ab485f8d43
10 changed files with 73 additions and 13 deletions

View File

@@ -435,6 +435,9 @@ public class FragmentAccount extends FragmentEx {
account.synchronize = synchronize;
account.primary = (account.synchronize && args.getBoolean("primary"));
if (!synchronize)
account.error = null;
if (account.primary)
db.account().resetPrimary();
@@ -443,9 +446,6 @@ public class FragmentAccount extends FragmentEx {
else
account.id = db.account().insertAccount(account);
if (!synchronize)
db.account().setAccountError(account.id, null);
List<EntityFolder> folders = new ArrayList<>();
EntityFolder inbox = new EntityFolder();
@@ -479,7 +479,7 @@ public class FragmentAccount extends FragmentEx {
}
for (EntityFolder folder : folders) {
db.folder().setFolderUser(folder.account, folder.type);
db.folder().setFolderUser(account.id, folder.type);
EntityFolder existing = db.folder().getFolderByName(account.id, folder.name);
if (existing == null) {
folder.account = account.id;