直播间退出闪烁

This commit is contained in:
18401019693 2022-09-07 13:03:28 +08:00
parent 9cb4714b78
commit 5b59ce8c89
3 changed files with 30 additions and 16 deletions

View File

@ -6,6 +6,7 @@
<item name="colorPrimaryDark">@color/colorPrimaryDark</item> <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item> <item name="colorAccent">@color/colorAccent</item>
<item name="android:colorBackground">@color/background</item> <item name="android:colorBackground">@color/background</item>
<item name="android:windowAnimationStyle">@style/Animation</item>
</style> </style>
<style name="dialog" parent="AppTheme"> <style name="dialog" parent="AppTheme">
@ -99,5 +100,20 @@
<item name="android:windowFullscreen">true</item> <item name="android:windowFullscreen">true</item>
<item name="android:backgroundDimEnabled">true</item> <item name="android:backgroundDimEnabled">true</item>
</style> </style>
<!--关掉Activity转场动画-->
<style name="Animation">
<item name="android:activityOpenEnterAnimation">@null</item>
<item name="android:activityOpenExitAnimation">@null</item>
<item name="android:activityCloseEnterAnimation">@null</item>
<item name="android:activityCloseExitAnimation">@null</item>
<item name="android:taskOpenEnterAnimation">@null</item>
<item name="android:taskOpenExitAnimation">@null</item>
<item name="android:taskCloseEnterAnimation">@null</item>
<item name="android:taskCloseExitAnimation">@null</item>
<item name="android:taskToFrontEnterAnimation">@null</item>
<item name="android:taskToFrontExitAnimation">@null</item>
<item name="android:taskToBackEnterAnimation">@null</item>
<item name="android:taskToBackExitAnimation">@null</item>
</style>
</resources> </resources>

View File

@ -1,7 +1,5 @@
package com.yunbao.live.activity; package com.yunbao.live.activity;
import static com.yunbao.live.views.LivePlayRyViewHolder.Micing;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.content.Context; import android.content.Context;
import android.content.Intent; import android.content.Intent;
@ -48,10 +46,8 @@ import com.yunbao.common.pay.PayCallback;
import com.yunbao.common.pay.PayPresenter; import com.yunbao.common.pay.PayPresenter;
import com.yunbao.common.utils.Bus; import com.yunbao.common.utils.Bus;
import com.yunbao.common.utils.DialogUitl; import com.yunbao.common.utils.DialogUitl;
import com.yunbao.common.utils.DpUtil;
import com.yunbao.common.utils.L; import com.yunbao.common.utils.L;
import com.yunbao.common.utils.ProcessResultUtil; import com.yunbao.common.utils.ProcessResultUtil;
import com.yunbao.common.utils.RouteUtil;
import com.yunbao.common.utils.ToastUtil; import com.yunbao.common.utils.ToastUtil;
import com.yunbao.common.views.weight.VerticalViewPager; import com.yunbao.common.views.weight.VerticalViewPager;
import com.yunbao.live.R; import com.yunbao.live.R;
@ -68,7 +64,6 @@ import com.yunbao.live.dialog.SidebarLiveAudience;
import com.yunbao.live.event.LinkMicTxAccEvent; import com.yunbao.live.event.LinkMicTxAccEvent;
import com.yunbao.live.event.LiveAudienceEvent; import com.yunbao.live.event.LiveAudienceEvent;
import com.yunbao.live.event.LiveRoomChangeEvent; import com.yunbao.live.event.LiveRoomChangeEvent;
import com.yunbao.live.event.RecommendLiveRoomEvent;
import com.yunbao.live.http.ImHttpUtil; import com.yunbao.live.http.ImHttpUtil;
import com.yunbao.live.http.LiveHttpConsts; import com.yunbao.live.http.LiveHttpConsts;
import com.yunbao.live.http.LiveHttpUtil; import com.yunbao.live.http.LiveHttpUtil;
@ -83,6 +78,8 @@ import java.util.ArrayList;
import java.util.Arrays; import java.util.Arrays;
import java.util.List; import java.util.List;
import static com.yunbao.live.views.LivePlayRyViewHolder.Micing;
/** /**
* Created by cxf on 2018/10/10. * Created by cxf on 2018/10/10.
* 看直播 * 看直播
@ -450,9 +447,11 @@ public class LiveAudienceActivity extends LiveActivity {
} else if (Micing == 2) { } else if (Micing == 2) {
manager.micIngTypeTwo(mLiveBean, mLiveType, mLiveTypeVal); manager.micIngTypeTwo(mLiveBean, mLiveType, mLiveTypeVal);
} else { } else {
manager.exitLiveRoom();
manager.onRemove(); manager.onRemove();
super.onBackPressed(); verticalViewPager.removeAllViews();
finish();
overridePendingTransition(0, 0);
} }
} }
@ -809,6 +808,7 @@ public class LiveAudienceActivity extends LiveActivity {
/** /**
* 跳转到消息中心的系统信息web * 跳转到消息中心的系统信息web
*
* @param type 1官方通知 2互动信息 3在线客服 * @param type 1官方通知 2互动信息 3在线客服
*/ */
private void toSysMsgWeb(String type) { private void toSysMsgWeb(String type) {

View File

@ -1324,8 +1324,6 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
*/ */
public void endPlay() { public void endPlay() {
CommonAppContext.Ingroup = 0; CommonAppContext.Ingroup = 0;
mLiveAudienceViewHolder.handler.removeCallbacks(mLiveAudienceViewHolder.runnable);
mLiveAudienceViewHolder.handler1.removeCallbacks(mLiveAudienceViewHolder.runnable1);
if (mEnd) { if (mEnd) {
return; return;
} }