From 769f5275656d53f833d3bc0a0288ff39ea0e6cd1 Mon Sep 17 00:00:00 2001 From: Martin <13046765170@163.com> Date: Tue, 9 Jul 2024 13:08:33 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E9=96=8B=E9=80=9A=E5=AE=88=E8=AD=B7-?= =?UTF-8?q?=E4=BD=BF=E7=94=A8=E5=84=AA=E6=83=A0=E5=88=B8=202=E3=80=81?= =?UTF-8?q?=E5=BC=80=E9=80=9A=E8=B4=B5=E6=97=8F=EF=BC=8C=E5=9C=A8=E5=BD=93?= =?UTF-8?q?=E5=89=8D=E7=9B=B4=E6=92=AD=E9=97=B4=E6=9C=89=E5=9B=B4=E8=A7=82?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dialog/GuardBuyCouponTipsDialog.java | 1 - .../common/views/weight/NobleNoticeView.java | 19 +++++++++++++++---- .../main/res/layout/dialog_guard_buy_tips.xml | 6 +++--- common/src/main/res/values-zh-rHK/strings.xml | 2 +- common/src/main/res/values-zh-rTW/strings.xml | 2 +- common/src/main/res/values-zh/strings.xml | 2 +- common/src/main/res/values/strings.xml | 2 +- .../yunbao/live/views/LiveRoomViewHolder.java | 15 ++++++++------- 8 files changed, 30 insertions(+), 19 deletions(-) diff --git a/common/src/main/java/com/yunbao/common/dialog/GuardBuyCouponTipsDialog.java b/common/src/main/java/com/yunbao/common/dialog/GuardBuyCouponTipsDialog.java index fdb48d71e..38b86f353 100644 --- a/common/src/main/java/com/yunbao/common/dialog/GuardBuyCouponTipsDialog.java +++ b/common/src/main/java/com/yunbao/common/dialog/GuardBuyCouponTipsDialog.java @@ -57,7 +57,6 @@ public class GuardBuyCouponTipsDialog { dialog.findViewById(R.id.btn_cancel).setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { - simpleCallback.onCancel(); dialog.dismiss(); } }); diff --git a/common/src/main/java/com/yunbao/common/views/weight/NobleNoticeView.java b/common/src/main/java/com/yunbao/common/views/weight/NobleNoticeView.java index 99ea4e543..2dd5c9411 100644 --- a/common/src/main/java/com/yunbao/common/views/weight/NobleNoticeView.java +++ b/common/src/main/java/com/yunbao/common/views/weight/NobleNoticeView.java @@ -27,6 +27,7 @@ import com.opensource.svgaplayer.SVGAVideoEntity; import com.yunbao.common.R; import com.yunbao.common.glide.ImgLoader; import com.yunbao.common.utils.BitmapUtil; +import com.yunbao.common.utils.L; import com.yunbao.common.utils.SVGAViewUtils; import org.jetbrains.annotations.NotNull; @@ -56,6 +57,8 @@ public class NobleNoticeView extends FrameLayout { private HorizontalScrollView contextLayout; private RelativeLayout scrollLayout; private ImageView nobleIcon; + private String anchorUid; + private String mLiveId; public NobleNoticeView(@NonNull Context context) { super(context); @@ -97,9 +100,11 @@ public class NobleNoticeView extends FrameLayout { }); } - public NobleNoticeView setRootView(String uHead, String userNameStr, String anchorNicknameStr, String anchorUid) { + public NobleNoticeView setRootView(String uHead, String userNameStr, String anchorNicknameStr, String anchorUid,String mLiveId) { this.uhead = uHead; this.anchorNicknameStr = anchorNicknameStr.trim(); + this.anchorUid = anchorUid; + this.mLiveId = mLiveId; userName.setText(userNameStr); anchorNickname.setText(anchorNicknameStr.trim()); if (TextUtils.isEmpty(anchorNicknameStr.trim())) { @@ -112,6 +117,10 @@ public class NobleNoticeView extends FrameLayout { findViewById(R.id.anchor_nickname).setVisibility(VISIBLE); openNoble.setText(mContext.getString(R.string.open_noble)); } + if(anchorUid.equals(mLiveId)){ + L.eSw("showBuyVipMessage:"+anchorUid+"__"+mLiveId); + gotoRoomView.setVisibility(GONE); + } return this; } @@ -352,13 +361,15 @@ public class NobleNoticeView extends FrameLayout { gotoRoomView.setLayoutParams(layoutParams); contextLayout.setLayoutParams(contextLayoutParams); if (!TextUtils.isEmpty(anchorNicknameStr)) { - gotoRoomView.setVisibility(VISIBLE); + if(mLiveId.equals(anchorUid)){ + gotoRoomView.setVisibility(GONE); + }else{ + gotoRoomView.setVisibility(VISIBLE); + } findViewById(R.id.in).setVisibility(VISIBLE); findViewById(R.id.anchor_nickname).setVisibility(VISIBLE); } contextLayout.setVisibility(VISIBLE); - - }); } diff --git a/common/src/main/res/layout/dialog_guard_buy_tips.xml b/common/src/main/res/layout/dialog_guard_buy_tips.xml index c72c7269f..349c6fab4 100644 --- a/common/src/main/res/layout/dialog_guard_buy_tips.xml +++ b/common/src/main/res/layout/dialog_guard_buy_tips.xml @@ -2,13 +2,13 @@ 完成*1 主播正在PK,稍後再試 使用 - 取消 + 不使用 diff --git a/common/src/main/res/values-zh-rTW/strings.xml b/common/src/main/res/values-zh-rTW/strings.xml index 1f89b272c..a1e772120 100644 --- a/common/src/main/res/values-zh-rTW/strings.xml +++ b/common/src/main/res/values-zh-rTW/strings.xml @@ -1501,5 +1501,5 @@ 完成*1 主播正在PK,稍後再試 使用 - 取消 + 不使用 diff --git a/common/src/main/res/values-zh/strings.xml b/common/src/main/res/values-zh/strings.xml index 415ed8c98..b4cb55478 100644 --- a/common/src/main/res/values-zh/strings.xml +++ b/common/src/main/res/values-zh/strings.xml @@ -1498,6 +1498,6 @@ 完成*1 主播正在PK,稍後再試 使用 - 取消 + 不使用 diff --git a/common/src/main/res/values/strings.xml b/common/src/main/res/values/strings.xml index 6d6827531..16dd5cbc1 100644 --- a/common/src/main/res/values/strings.xml +++ b/common/src/main/res/values/strings.xml @@ -1507,5 +1507,5 @@ Limited ride And limited avatar frame The anchor is in PK, please try again later once Use - Cancel + Not use 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 e1b3aa58d..372f890af 100644 --- a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java @@ -4394,29 +4394,30 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis * @param bean */ public void showBuyVipMessage(LiveReceiveGiftBean bean) { + L.eSw("showBuyVipMessage:"+bean.getRoomnum()+"__"+mLiveUid); noble.setVisibility(View.VISIBLE); switch (bean.getNobilityid()) { case "1": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.BARON).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.BARON).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "2": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.VISCOUNT).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.VISCOUNT).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "3": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.MARQUIS).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.MARQUIS).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "4": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.DUKE).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.DUKE).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "5": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.KING).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.KING).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "6": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.EMPEROR).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.EMPEROR).setCallBack(() -> gotoLive(bean.getRoomnum())); break; case "7": - noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum()).setRoleType(NobleNoticeView.RoleType.BETTER_EMPEROR).setCallBack(() -> gotoLive(bean.getRoomnum())); + noble.setRootView(bean.getUhead(), bean.getUname(), bean.getAncherName(), bean.getRoomnum(),mLiveUid).setRoleType(NobleNoticeView.RoleType.BETTER_EMPEROR).setCallBack(() -> gotoLive(bean.getRoomnum())); break; } }