aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/pixart/messenger
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/main/java/de/pixart/messenger/ui/ConversationFragment.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
index f2127b48e..74ee1324d 100644
--- a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
+++ b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
@@ -1275,9 +1275,9 @@ public class ConversationFragment extends Fragment implements EditMessage.Keyboa
if (max == 0 || (max <= 1 && showLoadMoreMessages(conversation))){
this.messageList.add(0, Message.createDateMessage(conversation, getString(R.string.start_chatting)));
} else if ((max > 0 && !showLoadMoreMessages(conversation)) || (max > 1 && showLoadMoreMessages(conversation))) {
+ String date = first;
for (int i = (max - 1); i > 0; --i) {
String last = sdf.format(this.messageList.get(i).getTimeSent());
- String date = first;
if (!last.equals(first)) {
if (i < (max - 1)) {
if (today.equals(first)) {
@@ -1288,7 +1288,10 @@ public class ConversationFragment extends Fragment implements EditMessage.Keyboa
}
first = last;
}
- this.messageList.add(0, Message.createDateMessage(conversation, first));
+ if (today.equals(first)) {
+ date = getString(R.string.today);
+ }
+ this.messageList.add(0, Message.createDateMessage(conversation, date));
}
}
}