Merge branch 'master' into tmp_mon
# Conflicts: # main/src/main/java/com/yunbao/main/views/MainHomeViewHolder.java
This commit is contained in:
commit
0294296ada
@ -278,17 +278,17 @@ public class AppContext extends CommonAppContext {
|
|||||||
Log.e("ApplicationError", "主线程异常");//此处log只是展示,当debug为true时,主类内部log会打印异常信息
|
Log.e("ApplicationError", "主线程异常");//此处log只是展示,当debug为true时,主类内部log会打印异常信息
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
//闪退后finish所有Activity并且杀死进程
|
//闪退后finish所有Activity并且杀死进程
|
||||||
for (WeakReference<Activity> activity : activities) {
|
/* for (WeakReference<Activity> activity : activities) {
|
||||||
if (activity != null && activity.get() != null) {
|
if (activity != null && activity.get() != null) {
|
||||||
activity.get().finish();
|
activity.get().finish();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* Process.killProcess(Process.myPid());
|
*//* Process.killProcess(Process.myPid());
|
||||||
System.exit(0);*/
|
System.exit(0);*//*
|
||||||
setFirebaseCrashData();
|
setFirebaseCrashData();
|
||||||
new Handler(Looper.getMainLooper()).postDelayed(() -> {
|
new Handler(Looper.getMainLooper()).postDelayed(() -> {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}, 100);
|
}, 100);*/
|
||||||
})
|
})
|
||||||
.setUncaughtCrashHandler((t, e) -> {
|
.setUncaughtCrashHandler((t, e) -> {
|
||||||
Log.e("ApplicationError", "子线程异常");//此处log只是展示,当debug为true时,主类内部log会打印异常信息
|
Log.e("ApplicationError", "子线程异常");//此处log只是展示,当debug为true时,主类内部log会打印异常信息
|
||||||
|
@ -101,10 +101,10 @@ public class NeverCrashUtils {
|
|||||||
Log.e(TAG, "未捕获的主线程异常行为", e);
|
Log.e(TAG, "未捕获的主线程异常行为", e);
|
||||||
}
|
}
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
Toast.makeText(application, "发生闪退", Toast.LENGTH_SHORT).show();
|
Toast.makeText(application, "发生闪退:"+e.getMessage(), Toast.LENGTH_SHORT).show();
|
||||||
FileUtil.saveStringToFile(new File(application.getDir("files", Context.MODE_PRIVATE).getAbsolutePath()), throwableToString(e), "error.log");
|
FileUtil.saveStringToFile(new File(application.getDir("files", Context.MODE_PRIVATE).getAbsolutePath()), throwableToString(e), "error.log");
|
||||||
getMainCrashHandler().mainException(Looper.getMainLooper().getThread(), e);
|
getMainCrashHandler().mainException(Looper.getMainLooper().getThread(), e);
|
||||||
return;
|
// return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -10,9 +10,9 @@ ext {
|
|||||||
manifestPlaceholders = [
|
manifestPlaceholders = [
|
||||||
//正式
|
//正式
|
||||||
|
|
||||||
// serverHost : "https://napi.yaoulive.com",
|
serverHost : "https://napi.yaoulive.com",
|
||||||
//
|
//
|
||||||
serverHost : "https://ceshi.yaoulive.com",
|
// serverHost : "https://ceshi.yaoulive.com",
|
||||||
|
|
||||||
//腾讯地图
|
//腾讯地图
|
||||||
txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB",
|
txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB",
|
||||||
|
@ -688,7 +688,7 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
|
|
||||||
@Subscribe(threadMode = ThreadMode.MAIN)
|
@Subscribe(threadMode = ThreadMode.MAIN)
|
||||||
public void onLiveRoomChangeEvent(LiveRoomChangeEvent e) {
|
public void onLiveRoomChangeEvent(LiveRoomChangeEvent e) {
|
||||||
if (verticalViewPager.ismEnableScroll()) {
|
|
||||||
LiveBean liveBean = e.getLiveBean();
|
LiveBean liveBean = e.getLiveBean();
|
||||||
if (e.isLiveEnd()) {
|
if (e.isLiveEnd()) {
|
||||||
manager.removeLiveEnd();
|
manager.removeLiveEnd();
|
||||||
@ -707,9 +707,7 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
mAncherIcon = liveBean.getAvatar();
|
mAncherIcon = liveBean.getAvatar();
|
||||||
manager.onAdd(liveBean, mLiveType, mLiveTypeVal, mLiveSDK);
|
manager.onAdd(liveBean, mLiveType, mLiveTypeVal, mLiveSDK);
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
verticalViewPager.setEnableScroll(IMLoginManager.get(mContext).isSlide());
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -1244,13 +1242,11 @@ public class LiveAudienceActivity extends LiveActivity {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case SOCKET_LIVE_DRPK_SET_PK_VIEW:
|
case SOCKET_LIVE_DRPK_SET_PK_VIEW:
|
||||||
ToastUtil.show("setPkView");
|
|
||||||
if (manager.getmLivePlayViewHolder() != null) {
|
if (manager.getmLivePlayViewHolder() != null) {
|
||||||
manager.getmLivePlayViewHolder().setPkview();
|
manager.getmLivePlayViewHolder().setPkview();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case SOCKET_LIVE_DRPK_SET_PK_END_VIEW:
|
case SOCKET_LIVE_DRPK_SET_PK_END_VIEW:
|
||||||
ToastUtil.show("setPkEndview");
|
|
||||||
if (manager.getmLivePlayViewHolder() != null) {
|
if (manager.getmLivePlayViewHolder() != null) {
|
||||||
manager.getmLivePlayViewHolder().setPkEndview();
|
manager.getmLivePlayViewHolder().setPkEndview();
|
||||||
}
|
}
|
||||||
|
@ -608,10 +608,11 @@ public class EntryActivity extends AppCompatActivity {
|
|||||||
private void onLoginSuccess(int code, String msg, String[] info) {
|
private void onLoginSuccess(int code, String msg, String[] info) {
|
||||||
Log.e("他", code + "code" + info.toString());
|
Log.e("他", code + "code" + info.toString());
|
||||||
if (code == 0 && info.length > 0) {
|
if (code == 0 && info.length > 0) {
|
||||||
|
|
||||||
JSONObject obj = JSON.parseObject(info[0]);
|
JSONObject obj = JSON.parseObject(info[0]);
|
||||||
String uid = obj.getString("id");
|
String uid = obj.getString("id");
|
||||||
String token = obj.getString("token");
|
String token = obj.getString("token");
|
||||||
if (obj.getString("need_bind").equals("0")) {
|
if (obj.containsKey("need_bind") && obj.getString("need_bind").equals("0")) {
|
||||||
mFirstLogin = obj.getIntValue("first_login") == 1;
|
mFirstLogin = obj.getIntValue("first_login") == 1;
|
||||||
mShowInvite = obj.getIntValue("isagent") == 1;
|
mShowInvite = obj.getIntValue("isagent") == 1;
|
||||||
CommonAppConfig.getInstance().setLoginInfo(uid, token, true);
|
CommonAppConfig.getInstance().setLoginInfo(uid, token, true);
|
||||||
@ -687,7 +688,7 @@ public class EntryActivity extends AppCompatActivity {
|
|||||||
new LiveRoomCheckLivePresenter(activity, liveBean.getUid(), liveBean.getStream(), new LiveRoomCheckLivePresenter.NewActionListener() {
|
new LiveRoomCheckLivePresenter(activity, liveBean.getUid(), liveBean.getStream(), new LiveRoomCheckLivePresenter.NewActionListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onLiveRoomChanged(String liveUid, String stream, int liveType, String liveTypeVal, String liveSdk) {
|
public void onLiveRoomChanged(String liveUid, String stream, int liveType, String liveTypeVal, String liveSdk) {
|
||||||
RouteUtil.forwardLiveAudienceActivity(liveBean, liveType, Integer.parseInt(liveSdk), Integer.parseInt(liveTypeVal));
|
RouteUtil.forwardLiveAudienceActivity(liveBean, liveType, Integer.parseInt(liveSdk), Integer.parseInt(liveTypeVal));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
x
Reference in New Issue
Block a user