diff options
author | Daniel Gultsch <daniel@gultsch.de> | 2014-03-13 03:52:41 +0100 |
---|---|---|
committer | Daniel Gultsch <daniel@gultsch.de> | 2014-03-13 03:52:41 +0100 |
commit | a80e3131be975e35c85b3f746cef233fafebaae0 (patch) | |
tree | c5997e923a0d32527719546067429e78af7f33e2 /src/eu/siacs/conversations/ui/ConversationActivity.java | |
parent | eadebeb77cbc4f5b49d484b8a64058630385afe6 (diff) |
contact picture generation centralized + basic registry stuff
Diffstat (limited to 'src/eu/siacs/conversations/ui/ConversationActivity.java')
-rw-r--r-- | src/eu/siacs/conversations/ui/ConversationActivity.java | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/eu/siacs/conversations/ui/ConversationActivity.java b/src/eu/siacs/conversations/ui/ConversationActivity.java index ad6e6c38..a4309cd0 100644 --- a/src/eu/siacs/conversations/ui/ConversationActivity.java +++ b/src/eu/siacs/conversations/ui/ConversationActivity.java @@ -95,6 +95,7 @@ public class ConversationActivity extends XmppActivity { xmppConnectionService.createContact(contact); } }; + protected ConversationActivity activity = this; public List<Conversation> getConversationList() { return this.conversationList; @@ -177,17 +178,8 @@ public class ConversationActivity extends XmppActivity { ((TextView) view.findViewById(R.id.conversation_lastupdate)) .setText(UIHelper.readableTimeDifference(conv.getLatestMessage().getTimeSent())); - Uri profilePhoto = conv.getProfilePhotoUri(); ImageView imageView = (ImageView) view.findViewById(R.id.conversation_image); - if (profilePhoto!=null) { - imageView.setImageURI(profilePhoto); - } else { - imageView.setImageBitmap(UIHelper.getUnknownContactPicture(getItem(position).getName(),200)); - } - - - ((ImageView) view.findViewById(R.id.conversation_image)) - .setImageURI(conv.getProfilePhotoUri()); + imageView.setImageBitmap(UIHelper.getContactPicture(getItem(position).getContact(), 200, activity.getApplicationContext())); return view; } |