修复直播间多人PK时,用户赠送礼物后,顺序图片(1、2、3、4)闪烁问题
This commit is contained in:
parent
9984adfb8e
commit
16cb90d9bc
@ -198,6 +198,14 @@ public class ImgLoader {
|
||||
.skipMemoryCache(SKIP_MEMORY_CACHE)
|
||||
.into(imageView);
|
||||
}
|
||||
public static void displayNew(Context context, int res, ImageView imageView) {
|
||||
if (!contextIsExist(context)) {
|
||||
return;
|
||||
}
|
||||
Glide.with(context)
|
||||
.load(res)
|
||||
.into(imageView);
|
||||
}
|
||||
|
||||
/**
|
||||
* 显示视频封面缩略图
|
||||
|
@ -6193,26 +6193,26 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
||||
if (i == 0) {
|
||||
linearGrade1.setVisibility(View.VISIBLE);
|
||||
textPkName1.setText(userNiceName);
|
||||
ImgLoader.display(mContext, resScore, imageGrade1);
|
||||
ImgLoader.displayNew(mContext, resScore, imageGrade1);
|
||||
textGrade1.setText(String.valueOf(userScore));
|
||||
|
||||
} else if (i == 1) {
|
||||
linearGrade2.setVisibility(View.VISIBLE);
|
||||
textPkName2.setText(userNiceName);
|
||||
ImgLoader.display(mContext, resScore, imageGrade2);
|
||||
ImgLoader.displayNew(mContext, resScore, imageGrade2);
|
||||
textGrade2.setText(String.valueOf(userScore));
|
||||
userId2 = userId;
|
||||
} else if (i == 2) {
|
||||
if (pkScores.size() == 3) {
|
||||
linearGrade4.setVisibility(View.VISIBLE);
|
||||
textPkName4.setText(userNiceName);
|
||||
ImgLoader.display(mContext, resScore, imageGrade4);
|
||||
ImgLoader.displayNew(mContext, resScore, imageGrade4);
|
||||
textGrade4.setText(String.valueOf(userScore));
|
||||
userId4 = userId;
|
||||
} else {
|
||||
linearGrade3.setVisibility(View.VISIBLE);
|
||||
textPkName3.setText(userNiceName);
|
||||
ImgLoader.display(mContext, resScore, imageGrade3);
|
||||
ImgLoader.displayNew(mContext, resScore, imageGrade3);
|
||||
textGrade3.setText(String.valueOf(userScore));
|
||||
userId3 = userId;
|
||||
}
|
||||
@ -6220,7 +6220,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
||||
} else if (i == 3) {
|
||||
linearGrade4.setVisibility(View.VISIBLE);
|
||||
textPkName4.setText(userNiceName);
|
||||
ImgLoader.display(mContext, resScore, imageGrade4);
|
||||
ImgLoader.displayNew(mContext, resScore, imageGrade4);
|
||||
textGrade4.setText(String.valueOf(userScore));
|
||||
userId4 = userId;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user