added colon to seperate sender and message preview. only show first name

This commit is contained in:
Christian Schneppe 2017-03-09 20:12:51 +01:00
parent 1693f71543
commit c0756d5990

View file

@ -115,6 +115,7 @@ public class ConversationAdapter extends ArrayAdapter<Conversation> {
if (message.getFileParams().width > 0
&& (message.getTransferable() == null
|| message.getTransferable().getStatus() != Transferable.STATUS_DELETED)) {
mSenderName.setVisibility(View.GONE);
mLastMessage.setVisibility(View.GONE);
imagePreview.setVisibility(View.VISIBLE);
activity.loadBitmap(message, imagePreview);
@ -143,13 +144,13 @@ public class ConversationAdapter extends ArrayAdapter<Conversation> {
if (message.getStatus() == Message.STATUS_RECEIVED) {
if (conversation.getMode() == Conversation.MODE_MULTI) {
mSenderName.setVisibility(View.VISIBLE);
mSenderName.setText(UIHelper.getMessageDisplayName(message));
mSenderName.setText(UIHelper.getMessageDisplayName(message).split("\\s+")[0]+':');
} else {
mSenderName.setVisibility(View.GONE);
}
} else {
mSenderName.setVisibility(View.VISIBLE);
mSenderName.setText(activity.getString(R.string.me));
mSenderName.setText(activity.getString(R.string.me)+':');
}
}