mirror of
https://codeberg.org/Mercury-IM/Mercury-IM
synced 2024-11-15 20:22:05 +01:00
Display Roster name in roster activity
This commit is contained in:
parent
ac4ff2527b
commit
f773680288
2 changed files with 5 additions and 5 deletions
|
@ -65,8 +65,8 @@ public class RosterRecyclerViewAdapter
|
|||
@BindView(R.id.roster_entry__jid)
|
||||
TextView jidView;
|
||||
|
||||
@BindView(R.id.roster_entry__nickname)
|
||||
TextView nicknameView;
|
||||
@BindView(R.id.roster_entry__name)
|
||||
TextView nameView;
|
||||
|
||||
@BindView(R.id.roster_entry__avatar)
|
||||
CircleImageView avatarView;
|
||||
|
@ -81,8 +81,8 @@ public class RosterRecyclerViewAdapter
|
|||
}
|
||||
|
||||
void bind(RoomContactModel contactModel) {
|
||||
String nick = contactModel.getNickname();
|
||||
nicknameView.setText(nick != null ? nick : "");
|
||||
String name = contactModel.getRosterName();
|
||||
nameView.setText(name != null ? name : contactModel.getEntity().getJid().getLocalpart().asUnescapedString());
|
||||
EntityBareJid jid = contactModel.getEntity().getJid();
|
||||
jidView.setText(jid.toString());
|
||||
jidView.setTextColor(ColorUtil.consistentColor(jid.toString(), new ConsistentColor.ConsistentColorSettings(ConsistentColor.Deficiency.none)));
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
tools:srcCompat="@drawable/aldrin" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/roster_entry__nickname"
|
||||
android:id="@+id/roster_entry__name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="@tools:sample/full_names"
|
||||
|
|
Loading…
Reference in a new issue