Merge remote-tracking branch 'origin/dev_robotaxi-d-app-module_251_220125_2.5.1' into dev_robotaxi-d-app-module_251_220125_2.5.1

This commit is contained in:
donghongyu
2022-02-16 15:49:39 +08:00
2 changed files with 9 additions and 3 deletions

View File

@@ -51,17 +51,17 @@ public class OchBusProvider implements IMogoOCH {
if (busFragment == null) { if (busFragment == null) {
Logger.d(TAG, "准备add fragment======"); Logger.d(TAG, "准备add fragment======");
busFragment = new OchBusFragment(); busFragment = new OchBusFragment();
activity.getSupportFragmentManager().beginTransaction().add(containerId, busFragment).commit(); activity.getSupportFragmentManager().beginTransaction().add(containerId, busFragment).commitAllowingStateLoss();
return; return;
} }
Logger.d(TAG, "准备show fragment"); Logger.d(TAG, "准备show fragment");
activity.getSupportFragmentManager().beginTransaction().show(busFragment).commit(); activity.getSupportFragmentManager().beginTransaction().show(busFragment).commitAllowingStateLoss();
} }
private void hideFragment() { private void hideFragment() {
if (busFragment != null) { if (busFragment != null) {
Logger.d(TAG, "准备hide fragment"); Logger.d(TAG, "准备hide fragment");
activity.getSupportFragmentManager().beginTransaction().hide(busFragment).commit(); activity.getSupportFragmentManager().beginTransaction().hide(busFragment).commitAllowingStateLoss();
} }
} }

View File

@@ -284,10 +284,16 @@ class DebugSettingView @JvmOverloads constructor(
SharedPrefsMgr.getInstance(context).getBoolean(MoGoConfig.IS_DEMO_MODE, false) SharedPrefsMgr.getInstance(context).getBoolean(MoGoConfig.IS_DEMO_MODE, false)
CallerAutoPilotManager.setDemoMode(isDemoMode) CallerAutoPilotManager.setDemoMode(isDemoMode)
tbIsDemoMode.isChecked = isDemoMode tbIsDemoMode.isChecked = isDemoMode
if (isDemoMode){
FunctionBuildConfig.isIgnoreConditionsDrawAutopilotTrajectoryData = true
}
// 演示模式 // 演示模式
tbIsDemoMode.setOnCheckedChangeListener { buttonView, isChecked -> tbIsDemoMode.setOnCheckedChangeListener { buttonView, isChecked ->
CallerAutoPilotManager.setDemoMode(isChecked) CallerAutoPilotManager.setDemoMode(isChecked)
FunctionBuildConfig.isDemoMode = isChecked FunctionBuildConfig.isDemoMode = isChecked
if (!FunctionBuildConfig.isDemoMode){
FunctionBuildConfig.isIgnoreConditionsDrawAutopilotTrajectoryData = false
}
SharedPrefsMgr.getInstance(context).putBoolean(MoGoConfig.IS_DEMO_MODE, isChecked) SharedPrefsMgr.getInstance(context).putBoolean(MoGoConfig.IS_DEMO_MODE, isChecked)
} }