From b28551291418d1776d674de95c73eea33ae6b809 Mon Sep 17 00:00:00 2001 From: zlzw <583819556@qq.com> Date: Wed, 3 Apr 2024 15:06:00 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20[=E5=9C=A8=E7=9B=B4?= =?UTF-8?q?=E6=92=AD=E9=97=B4=E4=B8=AD=EF=BC=8C=E5=8F=AA=E6=9C=89=E6=99=AE?= =?UTF-8?q?=E9=80=9A=E6=B6=88=E6=81=AF=E6=89=8D=E8=83=BD=E6=94=B6=E5=88=B0?= =?UTF-8?q?=E6=8E=A8=E9=80=81=E5=BC=B9=E7=AA=97]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/com/shayu/phonelive/AppContext.java | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/shayu/phonelive/AppContext.java b/app/src/main/java/com/shayu/phonelive/AppContext.java index d22f81d18..a5b3e3925 100644 --- a/app/src/main/java/com/shayu/phonelive/AppContext.java +++ b/app/src/main/java/com/shayu/phonelive/AppContext.java @@ -26,6 +26,7 @@ import com.blankj.utilcode.util.Utils; import com.facebook.appevents.AppEventsLogger; import com.fm.openinstall.OpenInstall; import com.google.gson.Gson; +import com.pandoralive.shayu.R; import com.shayu.phonelive.utils.LogUtils; import com.tencent.imsdk.v2.V2TIMGroupMemberInfo; import com.tencent.imsdk.v2.V2TIMManager; @@ -56,6 +57,7 @@ import com.yunbao.common.utils.L; import com.yunbao.common.utils.MessageChatNotifyManager; import com.yunbao.common.utils.MessageSayHiNotifyManager; import com.yunbao.common.utils.SpUtil; +import com.yunbao.common.utils.WordUtil; import com.yunbao.live.activity.LiveActivity; import com.yunbao.live.activity.SudGameActivity; import com.yunbao.live.socket.SocketReceiveBean; @@ -273,7 +275,14 @@ public class AppContext extends CommonAppContext { msg.what = Constants.SOCKET_WHAT_BROADCAST; try { if (!"".equals(message.getContent()) && message.getContent() != null) { - TextMessage content = (TextMessage) message.getContent(); + TextMessage content; + if (message.getContent() instanceof MessageChatCardContent) { + content = new TextMessage(WordUtil.getNewString(R.string.activity_msg_chat_list_card)); + } else if (message.getContent() instanceof TextMessage) { + content = (TextMessage) message.getContent(); + }else{ + return false; + } if (content.getContent().contains("_method_")) { msg.obj = content.getContent(); //观众页面