Merge branch 'development' into CryptoNextAlpha

* development:
  show contacts name in non anonymous mucs. fixes #1213
This commit is contained in:
Andreas Straub 2015-07-08 18:16:05 +02:00
commit 34f90f2eb7
1 changed files with 6 additions and 2 deletions

View File

@ -221,10 +221,14 @@ public class UIHelper {
public static String getMessageDisplayName(final Message message) {
if (message.getStatus() == Message.STATUS_RECEIVED) {
if (message.getConversation().getMode() == Conversation.MODE_MULTI) {
return getDisplayedMucCounterpart(message.getCounterpart());
} else {
final Contact contact = message.getContact();
if (message.getConversation().getMode() == Conversation.MODE_MULTI) {
if (contact != null) {
return contact.getDisplayName();
} else {
return getDisplayedMucCounterpart(message.getCounterpart());
}
} else {
return contact != null ? contact.getDisplayName() : "";
}
} else {