-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Description
Im trying to use the get avatar method but it returns the default value and not the image of the contact:
public Drawable getAvatar(final Context context, final Drawable defaultValue) {
Log.d(TAG, "getAvatar()");
if (this.mAvatar == null) {
if (this.mAvatarData != null) {
Bitmap b = BitmapFactory.decodeByteArray(this.mAvatarData, 0,
this.mAvatarData.length);
this.mAvatar = new BitmapDrawable(context.getResources(), b);
Log.d(TAG, "BitmapSet");
}
}
if (this.mAvatar == null) {
Log.d(TAG, "ImageNotAvailable");
return defaultValue;
}
return this.mAvatar;
}
Metadata
Metadata
Assignees
Labels
No labels