修复滑动直播间不显示离开图

This commit is contained in:
zlzw 2022-11-03 14:47:06 +08:00
parent 302435c068
commit c3c91ba9a2
2 changed files with 7 additions and 7 deletions

View File

@ -159,7 +159,7 @@ public abstract class LiveActivity extends AbsActivity implements SocketMessageL
EventBus.getDefault().register(this); EventBus.getDefault().register(this);
mDialogFragmentSet = new HashSet<>(); mDialogFragmentSet = new HashSet<>();
//解压 美颜模型 //解压 美颜模型
try { /*try {
CommonAppConfig.VIDEO_TIE_MODEl_PATH = getFilesDir().getAbsolutePath() + "/model";//app安装路径 CommonAppConfig.VIDEO_TIE_MODEl_PATH = getFilesDir().getAbsolutePath() + "/model";//app安装路径
File model = new File(CommonAppConfig.VIDEO_TIE_MODEl_PATH); File model = new File(CommonAppConfig.VIDEO_TIE_MODEl_PATH);
if (model.exists() && Objects.requireNonNull(model.listFiles()).length > 0) { if (model.exists() && Objects.requireNonNull(model.listFiles()).length > 0) {
@ -169,7 +169,7 @@ public abstract class LiveActivity extends AbsActivity implements SocketMessageL
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
Log.i("log", "beauty e=" + e); Log.i("log", "beauty e=" + e);
} }*/
} }
@Override @Override

View File

@ -172,6 +172,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
private boolean mCoinNotEnough;//余额不足 private boolean mCoinNotEnough;//余额不足
private boolean mFirstConnectSocket;//是否是第一次连接成功socket private boolean mFirstConnectSocket;//是否是第一次连接成功socket
private int liveBg = -1; private int liveBg = -1;
private int leave=-1;//是否正在休息 1为休息 0为直播
private LiveImDeletUtil liveImDeletUtil; private LiveImDeletUtil liveImDeletUtil;
private List<String> greetings = new ArrayList<>(); private List<String> greetings = new ArrayList<>();
private Handler liveHandler = new Handler(); private Handler liveHandler = new Handler();
@ -1069,7 +1070,7 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
mChatLevel = obj.getIntValue("speak_limit"); mChatLevel = obj.getIntValue("speak_limit");
mDanMuLevel = obj.getIntValue("barrage_limit"); mDanMuLevel = obj.getIntValue("barrage_limit");
liveBg = obj.getIntValue("live_bg"); liveBg = obj.getIntValue("live_bg");
leave = obj.getInteger("isleave");
if (obj.containsKey("greetings")) { if (obj.containsKey("greetings")) {
greetings = JSONArray.parseArray(obj.getJSONArray("greetings").toJSONString(), String.class); greetings = JSONArray.parseArray(obj.getJSONArray("greetings").toJSONString(), String.class);
} }
@ -1197,10 +1198,9 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
mLiveRoomViewHolder.startRequestTimeCharge(); mLiveRoomViewHolder.startRequestTimeCharge();
} }
} }
if (leave==1) {
if (TextUtils.equals(obj.getString("isleave"), "1")) { if (LivePlayRyViewHolder.leave != null) {
if (LivePlayKsyViewHolder.leave != null) { LivePlayRyViewHolder.leave.setVisibility(View.VISIBLE);
LivePlayKsyViewHolder.leave.setVisibility(View.VISIBLE);
} }
} }
//判断是否有连麦要显示连麦窗口 //判断是否有连麦要显示连麦窗口