diff options
author | iNPUTmice <daniel@gultsch.de> | 2014-08-31 18:55:15 +0200 |
---|---|---|
committer | iNPUTmice <daniel@gultsch.de> | 2014-08-31 18:55:15 +0200 |
commit | 94389ac22a1dd3d4e9bff1b64b6c74fa82c55084 (patch) | |
tree | acb18d7d9d6ef1d9b61c4fcf50c4c1424930e299 /src/eu/siacs/conversations/entities | |
parent | bda7724e317dd46f831df29c4c920b3913c533cb (diff) |
show merged time and status in message adapter
Diffstat (limited to 'src/eu/siacs/conversations/entities')
-rw-r--r-- | src/eu/siacs/conversations/entities/Message.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/entities/Message.java b/src/eu/siacs/conversations/entities/Message.java index 2dc1bfb5..84aac4f5 100644 --- a/src/eu/siacs/conversations/entities/Message.java +++ b/src/eu/siacs/conversations/entities/Message.java @@ -336,6 +336,24 @@ public class Message extends AbstractEntity { } return body.trim(); } + + public int getMergedStatus() { + Message next = this.next(); + if (this.mergable(next)) { + return next.getMergedStatus(); + } else { + return getStatus(); + } + } + + public long getMergedTimeSent() { + Message next = this.next(); + if (this.mergable(next)) { + return next.getMergedTimeSent(); + } else { + return getTimeSent(); + } + } public boolean wasMergedIntoPrevious() { Message prev = this.prev(); |