aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java')
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java b/src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java
index 67433b31..626b1bf3 100644
--- a/src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java
+++ b/src/main/java/de/thedevstack/conversationsplus/utils/MessageUtil.java
@@ -18,6 +18,16 @@ import de.thedevstack.conversationsplus.persistance.FileBackend;
*/
public final class MessageUtil {
+ public static boolean isMessageSent(Message message) {
+ switch (message.getStatus()) {
+ case Message.STATUS_SEND:
+ case Message.STATUS_SEND_DISPLAYED:
+ case Message.STATUS_SEND_RECEIVED:
+ return true;
+ default:
+ return false;
+ }
+ }
public static boolean markMessage(Conversation conversation, String uuid, int status) {
if (uuid == null) {