diff --git a/app/src/main/java/eu/faircode/email/EntityIdentity.java b/app/src/main/java/eu/faircode/email/EntityIdentity.java index a830d038f0..704695a21f 100644 --- a/app/src/main/java/eu/faircode/email/EntityIdentity.java +++ b/app/src/main/java/eu/faircode/email/EntityIdentity.java @@ -90,7 +90,7 @@ public class EntityIdentity { @NonNull public Boolean primary; @NonNull - public Boolean self = true; // obsolete + public Boolean self = true; @NonNull public Boolean sender_extra = false; public String sender_extra_regex; diff --git a/app/src/main/java/eu/faircode/email/EntityMessage.java b/app/src/main/java/eu/faircode/email/EntityMessage.java index 4cfc4117af..5c8865c98c 100644 --- a/app/src/main/java/eu/faircode/email/EntityMessage.java +++ b/app/src/main/java/eu/faircode/email/EntityMessage.java @@ -214,6 +214,7 @@ public class EntityMessage implements Serializable { for (Address sender : senders) for (TupleIdentityEx identity : identities) if (identity.account == account && + identity.self && identity.similarAddress(sender)) return true; @@ -234,6 +235,7 @@ public class EntityMessage implements Serializable { for (Address address : new ArrayList<>(addresses)) for (TupleIdentityEx identity : identities) if (identity.account == account && + identity.self && identity.similarAddress(address)) addresses.remove(address); diff --git a/app/src/main/res/layout/fragment_identity.xml b/app/src/main/res/layout/fragment_identity.xml index 25515297cc..56d6d9875d 100644 --- a/app/src/main/res/layout/fragment_identity.xml +++ b/app/src/main/res/layout/fragment_identity.xml @@ -546,7 +546,6 @@ android:layout_marginTop="12dp" android:checked="true" android:text="@string/title_self_identity" - android:visibility="gone" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@id/cbPrimary" /> @@ -826,7 +825,7 @@ tvUser,etUser,tvPassword,tilPassword,tvCaseSensitiveHint,btnCertificate,tvCertificate,btnOAuth, tvRealm,etRealm, cbUseIp,tvUseIpHint,tvEhlo,etEhlo, - cbSynchronize,cbPrimary, + cbSynchronize,cbPrimary,cbSelf, cbSenderExtra,tvSenderExtra,etSenderExtra,tvSenderExtraHint, tvReplyTo,etReplyTo,tvCc,etCc,tvCcHint,tvBcc,etBcc,tvBccHint, cbUnicode,tvMaxSize,etMaxSize" />