mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-18 03:48:08 +00:00
Fix chat room avatar when network is not reachable
This commit is contained in:
parent
a6dcc769b5
commit
cfee8b20e6
2 changed files with 7 additions and 12 deletions
|
|
@ -119,7 +119,6 @@ public class ChatListFragment extends Fragment implements ContactsUpdatedListene
|
|||
@Override
|
||||
public void onConferenceJoined(ChatRoom cr, EventLog eventLog) {
|
||||
refreshChatRoomsList();
|
||||
cr.removeListener(mChatRoomRefresher);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -294,18 +294,14 @@ public class ChatRoomsAdapter extends ListSelectionAdapter {
|
|||
} else {
|
||||
holder.displayName.setText(chatRoom.getSubject());
|
||||
ChatRoomSecurityLevel level = chatRoom.getSecurityLevel();
|
||||
if (LinphoneManager.getLc().limeV2Enabled()) {
|
||||
if (level == ChatRoomSecurityLevel.Safe) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_secure2);
|
||||
} else if (level == ChatRoomSecurityLevel.Unsafe) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_unsecure);
|
||||
} else if (level == ChatRoomSecurityLevel.Encrypted) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_secure1);
|
||||
} else {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_unregistered);
|
||||
}
|
||||
if (level == ChatRoomSecurityLevel.Safe) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_secure2);
|
||||
} else if (level == ChatRoomSecurityLevel.Unsafe) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_unsecure);
|
||||
} else if (level == ChatRoomSecurityLevel.Encrypted) {
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_secure1);
|
||||
} else {
|
||||
holder.contactPicture.setImageBitmap(mDefaultGroupBitmap);
|
||||
holder.contactPicture.setImageResource(R.drawable.avatar_group_small_unregistered);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue