From 1eb43fb8cfcb9f5f115579c5640588d44e983304 Mon Sep 17 00:00:00 2001 From: zlzw <583819556@qq.com> Date: Sat, 20 Jan 2024 15:15:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DPK=E6=8E=92=E4=BD=8D=E8=B5=9B?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/yunbao/live/views/LiveRoomViewHolder.java | 8 ++++---- .../java/com/yunbao/live/views/PortraitLiveManager.java | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) 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 85f0ef2d0..e12f547e0 100644 --- a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java @@ -2459,9 +2459,6 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis } pkRankLayout.setTag(mLiveUid); pkUidTmp = pkUid; - mRedVal.setVisibility(View.GONE); - mBlueVal.setVisibility(View.GONE); - mPkRankTopIcon.setVisibility(View.GONE); new LoadDian9TuUtil().loadDian9TuAssets2(mContext, liveRankPk2, "rectangle_new.png", 1); } @@ -2491,7 +2488,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis } } - public void initRankPKInfo(String mLiveUid) { + public void initRankPKInfo(String mLiveUid,String pkUid) { LiveNetManager.get(mContext) .getRandomPk(mLiveUid, pkUid, new com.yunbao.common.http.base.HttpCallback() { @Override @@ -2849,6 +2846,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis pkUid = ""; goto_room_view.setVisibility(View.GONE); livePKUserListBean = new LivePKUserListBean(); + mRedVal.setVisibility(View.GONE); + mBlueVal.setVisibility(View.GONE); + mPkRankTopIcon.setVisibility(View.GONE); } /** diff --git a/live/src/main/java/com/yunbao/live/views/PortraitLiveManager.java b/live/src/main/java/com/yunbao/live/views/PortraitLiveManager.java index b3d43a797..6f8dc6ea3 100644 --- a/live/src/main/java/com/yunbao/live/views/PortraitLiveManager.java +++ b/live/src/main/java/com/yunbao/live/views/PortraitLiveManager.java @@ -501,8 +501,6 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe mLiveRoomViewHolder.setUserList(data.getEnterRoomInfo().getUserlists()); //设置靓号 mLiveRoomViewHolder.setAnchorGoodNumber(data.getLiveInfo().getGoodnum()); - //初始化天梯赛信息 - mLiveRoomViewHolder.initRankPKInfo(String.valueOf(data.getLiveInfo().getUid())); if (!StringUtil.isEmpty(mLiveBean.getGiftId())) { mLiveRoomViewHolder.openGiftDialog(mLiveBean.getGiftId()); } @@ -625,6 +623,8 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe pkInfo = JSON.parseObject(GsonUtils.toJson(data.getEnterRoomInfo().getPkinfo())); if (pkInfo != null && pkInfo.getIntValue("drpk_status") != 1) { String pkUid = pkInfo.getString("pkuid"); + //初始化天梯赛信息 + mLiveRoomViewHolder.initRankPKInfo(String.valueOf(data.getLiveInfo().getUid()),pkUid); anyway = "1"; if (!TextUtils.isEmpty(pkUid) && !"0".equals(pkUid) && anyway.equals("0")) { if (mLiveSDK != Constants.LIVE_SDK_TX) {