整理hardcode问题,整理imageUtils工具类

This commit is contained in:
kehaoyuan
2017-10-19 09:11:22 +08:00
parent 3d7e994b93
commit 8d0ab82f15
51 changed files with 261 additions and 192 deletions

View File

@ -3,7 +3,6 @@ package com.gh.common.util;
import android.app.Dialog;
import android.content.Context;
import android.graphics.Color;
import android.net.Uri;
import android.support.v4.content.ContextCompat;
import android.text.TextUtils;
import android.view.View;
@ -291,7 +290,7 @@ public class CommentUtils {
} else {
holder.commentUserNameTv.setText(entity.getUser().getName());
if (TextUtils.isEmpty(entity.getUser().getIcon())) {
holder.commentUserIconDv.setImageURI(Uri.parse("res:///" + R.drawable.user_default_icon_comment));
ImageUtils.Companion.display(holder.commentUserIconDv, R.drawable.user_default_icon_comment);
} else {
ImageUtils.Companion.display(holder.commentUserIconDv, entity.getUser().getIcon());
}