From 8644c4676a5fda9d642244ff70e72c5fe524a24d Mon Sep 17 00:00:00 2001 From: steckbrief Date: Wed, 13 Jan 2016 16:10:09 +0100 Subject: Moved all avatar related work to AvatarService - fetchAvatar, fetchAvatarPep, fetchAvatarVcard, checkForAvatar moved from XmppConnectionService to AvatarService - Several unused imports removed - XmppSendUtil introduced to enable presencePacket and iqPacket sending without using XmppConnectionService since the account has everything needed - UiUpdateHelper introduced to enable UI updates without using XmppConnectionService directly --- .../de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/main/java/de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java') diff --git a/src/main/java/de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java b/src/main/java/de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java index e8d822c8..a61d0b4b 100644 --- a/src/main/java/de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java +++ b/src/main/java/de/thedevstack/conversationsplus/ui/ContactDetailsActivity.java @@ -36,6 +36,7 @@ import de.thedevstack.conversationsplus.crypto.PgpEngine; import de.thedevstack.conversationsplus.entities.Account; import de.thedevstack.conversationsplus.entities.Contact; import de.thedevstack.conversationsplus.entities.ListItem; +import de.thedevstack.conversationsplus.services.AvatarService; import de.thedevstack.conversationsplus.services.XmppConnectionService.OnAccountUpdate; import de.thedevstack.conversationsplus.services.XmppConnectionService.OnRosterUpdate; import de.thedevstack.conversationsplus.ui.listeners.ShowResourcesListDialogListener; @@ -351,7 +352,7 @@ public class ContactDetailsActivity extends XmppActivity implements OnAccountUpd } contactJidTv.setOnClickListener(new ShowResourcesListDialogListener(ContactDetailsActivity.this, contact)); accountJidTv.setText(getString(R.string.using_account, contact.getAccount().getJid().toBareJid())); - badge.setImageBitmap(avatarService().get(contact, getPixel(72))); + badge.setImageBitmap(AvatarService.getInstance().get(contact, getPixel(72))); badge.setOnClickListener(this.onBadgeClick); keys.removeAllViews(); -- cgit v1.2.3