new#优化Vr模式下故障求助

This commit is contained in:
wujifei
2021-04-07 20:05:38 +08:00
parent 2f80a3ca83
commit 49d2f2a8f5
2 changed files with 20 additions and 8 deletions

View File

@@ -67,7 +67,7 @@ public class V2XCarForHelpScenario extends AbsV2XScenario<Boolean> implements IM
} else {
closeWindow();
}
// return;
return;
}
if (isShow) {
showButton();
@@ -98,8 +98,8 @@ public class V2XCarForHelpScenario extends AbsV2XScenario<Boolean> implements IM
public void showWindow() {
if (getV2XWindow() != null) {
ViewGroup.LayoutParams layoutParams = new ViewGroup.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
(int) V2XUtils.getApp().getResources().getDimension(R.dimen.dp_140));
ViewGroup.LayoutParams.MATCH_PARENT,
(int) V2XUtils.getApp().getResources().getDimension(R.dimen.dp_140));
V2XServiceManager.getMogoTopViewManager().addView(getV2XWindow().getView(), layoutParams);
getV2XWindow().show(getV2XMessageEntity().getContent());
}
@@ -107,9 +107,9 @@ public class V2XCarForHelpScenario extends AbsV2XScenario<Boolean> implements IM
@Override
public void closeWindow() {
if (getV2XWindow() != null) {
getV2XWindow().close();
}
// if (getV2XWindow() != null) {
// getV2XWindow().close();
// }
}
private V2XVoiceCallbackListener cancelCb = null;

View File

@@ -75,10 +75,8 @@ public class V2XCarForHelpWindow extends V2XBasWindow implements IV2XWindow<Bool
V2XServiceManager.getV2XRefreshModel().cancelHelpSignal(new V2XRefreshCallback<BaseData>() {
@Override
public void onSuccess(BaseData result) {
AIAssist.getInstance(V2XUtils.getApp()).speakTTSVoice("已取消", null);
//移除窗体
V2XServiceManager.getMogoTopViewManager().removeView(V2XCarForHelpWindow.this);
V2XVoiceManager.INSTANCE.unRegisterWakeCmd(V2XVoiceConstants.COMMAND_ZHIDAO_V2X_CANCEL_HELP);
}
@Override
@@ -86,6 +84,20 @@ public class V2XCarForHelpWindow extends V2XBasWindow implements IV2XWindow<Bool
Toast.makeText(V2XServiceManager.getContext(), msg, Toast.LENGTH_SHORT).show();
}
});
}
AIAssist.getInstance(V2XUtils.getApp()).speakTTSVoice("已取消", null);
//移除窗体
V2XServiceManager.getMogoTopViewManager().removeView(V2XCarForHelpWindow.this);
V2XVoiceManager.INSTANCE.unRegisterWakeCmd(V2XVoiceConstants.COMMAND_ZHIDAO_V2X_CANCEL_HELP);
if (V2XServiceManager.getMoGoV2XStatusManager().isOtherSeekHelpPOIShow()) {
// 移除线
V2XServiceManager.getMoGoV2XPolylineManager().clearLine();
// 移除事件POI
V2XServiceManager.getMoGoV2XMarkerManager().clearSpecialCarPOI();
// 绘制上次的数据
V2XServiceManager.getMoGoV2XMarkerManager().drawableLastAllPOI();
}
}