diff --git a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java index f1baed586..b7e187654 100644 --- a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java @@ -1540,6 +1540,10 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis pkRankVf.addView(titleIcon); pkRankVf.addView(hourView); pkRankVf.startFlipping(); + + if(StringUtil.isEmpty(bean.getPkTopImgUrl())){ + return; + } if(Integer.parseInt(bean.getRedVal())>2) { mRedVal.setVisibility(View.VISIBLE); mRedVal.setText(bean.getRedVal() + "連勝"); @@ -1548,7 +1552,8 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis mBlueVal.setVisibility(View.VISIBLE); mBlueVal.setText(bean.getBlueVal() + "連勝"); } - //ImgLoader.display(mContext,bean.getPkTopImgUrl(),mPkRankTopIcon); + mPkRankTopIcon.setVisibility(View.VISIBLE); + ImgLoader.display(mContext,bean.getPkTopImgUrl(),mPkRankTopIcon); } }, Throwable::printStackTrace) .isDisposed(); @@ -1764,7 +1769,6 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis lt_pk_line.requestLayout(); lt_pk_line.setVisibility(View.VISIBLE); - mPkRankTopIcon.setVisibility(View.VISIBLE); img_pk_fist_l.setBackgroundResource(R.mipmap.icon_red_no1); img_pk_fist_r.setBackgroundResource(R.mipmap.icon_blue_no1); ImgLoader.display2((LiveActivity) Contexts, "", avatar_l1);