mirror of
https://gitlab.linphone.org/BC/public/linphone-android.git
synced 2026-01-18 11:58:09 +00:00
[UI] presence avatar updated
This commit is contained in:
parent
4540cad7f7
commit
9c739bf234
4 changed files with 6 additions and 4 deletions
|
|
@ -364,7 +364,6 @@ public class ChatListFragment extends Fragment implements OnClickListener, OnIte
|
|||
Long time;
|
||||
|
||||
AvatarWithPresenceImage avatarWithPresenceImage = (AvatarWithPresenceImage) view.findViewById(R.id.avatar_with_presence);
|
||||
avatarWithPresenceImage.setFormatAvatarImage(AvatarWithPresenceImage.AVATAR_SMALL);
|
||||
if(contact != null && contact.isLinphoneFriend()) {
|
||||
avatarWithPresenceImage.setLinphoneContact(contact);
|
||||
LinphoneManager.getInstance().addPresenceUpdatedListener(avatarWithPresenceImage);
|
||||
|
|
|
|||
|
|
@ -356,7 +356,7 @@ public class ContactsListFragment extends Fragment implements OnClickListener, O
|
|||
public void onPause() {
|
||||
instance = null;
|
||||
ContactsManager.removeContactsListener(this);
|
||||
LinphoneManager.getInstance().removePresenceUpdatedListener();
|
||||
//LinphoneManager.getInstance().removePresenceUpdatedListener();
|
||||
super.onPause();
|
||||
}
|
||||
|
||||
|
|
@ -435,7 +435,6 @@ public class ContactsListFragment extends Fragment implements OnClickListener, O
|
|||
}
|
||||
|
||||
AvatarWithPresenceImage avatarWithPresenceImage = (AvatarWithPresenceImage) view.findViewById(R.id.avatar_with_presence);
|
||||
avatarWithPresenceImage.setFormatAvatarImage(AvatarWithPresenceImage.AVATAR_SMALL);
|
||||
if(contact != null && contact.isLinphoneFriend()) {
|
||||
avatarWithPresenceImage.setLinphoneContact(contact);
|
||||
LinphoneManager.getInstance().addPresenceUpdatedListener(avatarWithPresenceImage);
|
||||
|
|
|
|||
|
|
@ -449,7 +449,6 @@ public class HistoryListFragment extends Fragment implements OnClickListener, On
|
|||
*/ holder.contact.setText(LinphoneUtils.getAddressDisplayName(address));
|
||||
// }
|
||||
|
||||
holder.avatarWithPresenceImage.setFormatAvatarImage(AvatarWithPresenceImage.AVATAR_SMALL);
|
||||
if(c != null && c.isLinphoneFriend() ) {
|
||||
holder.avatarWithPresenceImage.setLinphoneContact(c);
|
||||
LinphoneManager.getInstance().addPresenceUpdatedListener(holder.avatarWithPresenceImage);
|
||||
|
|
|
|||
|
|
@ -55,6 +55,11 @@ public class AvatarWithPresenceImage extends RelativeLayout implements onPresenc
|
|||
|
||||
friendStatusBig = (ImageView) this.findViewById(R.id.friend_status_big);
|
||||
contactPictureBig = (ImageView) this.findViewById(R.id.contact_picture_big);
|
||||
|
||||
friendStatusSmall.setVisibility(View.VISIBLE);
|
||||
contactPictureSmall.setVisibility(View.VISIBLE);
|
||||
friendStatusBig.setVisibility(View.GONE);
|
||||
contactPictureBig.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
public void setFormatAvatarImage(int format){
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue