kopia lustrzana https://github.com/ryukoposting/Signal-Android
Fix problem where recycled group avatar icons have stale listener
Fixes #7089 // FREEBIEfork-5.53.8
rodzic
671023d0c8
commit
4bd3094bad
|
@ -58,9 +58,7 @@ public class AvatarImageView extends ImageView {
|
|||
|
||||
private void setAvatarClickHandler(final Recipient recipient, boolean quickContactEnabled) {
|
||||
if (!recipient.isGroupRecipient() && quickContactEnabled) {
|
||||
setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
super.setOnClickListener(v -> {
|
||||
if (recipient.getContactUri() != null) {
|
||||
ContactsContract.QuickContact.showQuickContact(getContext(), AvatarImageView.this, recipient.getContactUri(), ContactsContract.QuickContact.MODE_LARGE, null);
|
||||
} else {
|
||||
|
@ -73,7 +71,6 @@ public class AvatarImageView extends ImageView {
|
|||
intent.setType(ContactsContract.Contacts.CONTENT_ITEM_TYPE);
|
||||
getContext().startActivity(intent);
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
super.setOnClickListener(listener);
|
||||
|
|
Ładowanie…
Reference in New Issue