diff options
author | iNPUTmice <daniel@gultsch.de> | 2014-10-20 21:08:33 +0200 |
---|---|---|
committer | iNPUTmice <daniel@gultsch.de> | 2014-10-20 21:08:33 +0200 |
commit | 21961673cbcb3132d2405c3d276058b94cbdbbfc (patch) | |
tree | a4cb9ef7f8c6395c2e7fc406f2c5a5e73ef1edcb /src/eu/siacs/conversations/entities/Contact.java | |
parent | 0bb2c3c4d5b2a4b676610276fafd50ea55f43706 (diff) |
refactored avatar generation. first step
Diffstat (limited to 'src/eu/siacs/conversations/entities/Contact.java')
-rw-r--r-- | src/eu/siacs/conversations/entities/Contact.java | 22 |
1 files changed, 4 insertions, 18 deletions
diff --git a/src/eu/siacs/conversations/entities/Contact.java b/src/eu/siacs/conversations/entities/Contact.java index 40eee73d..60c31a42 100644 --- a/src/eu/siacs/conversations/entities/Contact.java +++ b/src/eu/siacs/conversations/entities/Contact.java @@ -8,13 +8,9 @@ import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; -import eu.siacs.conversations.persistance.FileBackend; -import eu.siacs.conversations.utils.UIHelper; import eu.siacs.conversations.xml.Element; import android.content.ContentValues; -import android.content.Context; import android.database.Cursor; -import android.graphics.Bitmap; public class Contact implements ListItem { public static final String TABLENAME = "contacts"; @@ -330,20 +326,6 @@ public class Contact implements ListItem { } } - @Override - public Bitmap getImage(int size, Context context) { - if (this.avatar != null) { - Bitmap bm = FileBackend.getAvatar(avatar, size, context); - if (bm == null) { - return UIHelper.getContactPicture(this, size, context, false); - } else { - return bm; - } - } else { - return UIHelper.getContactPicture(this, size, context, false); - } - } - public boolean setAvatar(String filename) { if (this.avatar != null && this.avatar.equals(filename)) { return false; @@ -353,6 +335,10 @@ public class Contact implements ListItem { } } + public String getAvatar() { + return this.avatar; + } + public boolean deleteOtrFingerprint(String fingerprint) { boolean success = false; try { |