diff options
author | steckbrief <steckbrief@chefmail.de> | 2018-05-05 20:28:04 +0200 |
---|---|---|
committer | steckbrief <steckbrief@chefmail.de> | 2018-05-05 20:28:04 +0200 |
commit | b0780224b5bdd68d74ef514e64e14ce9d37d7b90 (patch) | |
tree | 04311ea20090216b4897bcb507d79c7e02f76eae /src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java | |
parent | 853f50e43f68599774469dd12240f35800144991 (diff) |
introduces new message state model
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java')
-rw-r--r-- | src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java b/src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java index a4def149..5e10f27c 100644 --- a/src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java +++ b/src/main/java/de/thedevstack/conversationsplus/services/avatar/AvatarCache.java @@ -12,8 +12,10 @@ import de.thedevstack.conversationsplus.entities.Conversation; import de.thedevstack.conversationsplus.entities.ListItem; import de.thedevstack.conversationsplus.entities.Message; import de.thedevstack.conversationsplus.entities.MucOptions; +import de.thedevstack.conversationsplus.enums.MessageDirection; import de.thedevstack.conversationsplus.utils.AvatarUtil; import de.thedevstack.conversationsplus.utils.ImageUtil; +import de.thedevstack.conversationsplus.utils.MessageUtil; import de.thedevstack.conversationsplus.utils.UIHelper; /** @@ -177,7 +179,7 @@ public final class AvatarCache { public static Bitmap get(Message message, int size, boolean cachedOnly) { final Conversation conversation = message.getConversation(); - if (message.getStatus() == Message.STATUS_RECEIVED) { + if (MessageUtil.isIncomingMessage(message)) { Contact c = message.getContact(); if (c != null && (c.getProfilePhoto() != null || c.getAvatar() != null)) { return get(c, size, cachedOnly); |