From 03ce6f249d2f0baad406b667f9dc2de56d5cbb78 Mon Sep 17 00:00:00 2001 From: xuxinchao <13522809046@163.com> Date: Wed, 11 May 2022 18:51:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E6=8E=A7=E6=9C=BA=E5=8D=87=E7=BA=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 调整工控机升级信息数据来源,改由云端获取,去掉之前由工控机获取数据逻辑 --- .../autopilot/adapter/MoGoAdasListenerImpl.kt | 22 +------- .../core/function/hmi/ui/MoGoHmiFragment.kt | 54 ------------------- .../api/hmi/warning/IMoGoWaringProvider.kt | 11 ---- .../function/call/hmi/CallerHmiManager.kt | 14 ----- 4 files changed, 1 insertion(+), 100 deletions(-) diff --git a/core/function-impl/mogo-core-function-autopilot/src/main/java/com/mogo/eagle/core/function/autopilot/adapter/MoGoAdasListenerImpl.kt b/core/function-impl/mogo-core-function-autopilot/src/main/java/com/mogo/eagle/core/function/autopilot/adapter/MoGoAdasListenerImpl.kt index 5af1137296..c07c7790ca 100644 --- a/core/function-impl/mogo-core-function-autopilot/src/main/java/com/mogo/eagle/core/function/autopilot/adapter/MoGoAdasListenerImpl.kt +++ b/core/function-impl/mogo-core-function-autopilot/src/main/java/com/mogo/eagle/core/function/autopilot/adapter/MoGoAdasListenerImpl.kt @@ -31,11 +31,7 @@ import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotIdentifyListen import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotPlanningListenerManager.invokeAutopilotRotting import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotPlanningListenerManager.invokeAutopilotTrajectory import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotVehicleStateListenerManager -import com.mogo.eagle.core.function.call.hmi.CallerHmiManager.showAdUpgradeStatus -import com.mogo.eagle.core.function.call.hmi.CallerHmiManager.showDockerRebootResult import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager -import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger -import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_ADAS_IMPL import com.zhidao.support.adas.high.AdasManager import com.zhidao.support.adas.high.OnAdasListener import com.zhidao.support.adas.high.bean.IPCUpgradeStateInfo @@ -327,23 +323,7 @@ class MoGoAdasListenerImpl : OnAdasListener { } override fun onUpgradeStateInfo(info: IPCUpgradeStateInfo) { - if (info != null) { - CallerLogger.d( - "$M_ADAS_IMPL$TAG", "onUpgradeStateInfo " + - " upgrade mode=" + info.upgradeMode + - " download status=" + info.downloadStatus + - " download progress current=" + info.progress.current + - " download progress total=" + info.progress.total + - " download version=" + info.images + - " upgrade status=" + info.upgradeStatus - ) - showAdUpgradeStatus( - info.upgradeMode, info.downloadStatus, info.progress.current, - info.progress.total, info.images, info.upgradeStatus - ) - } else { - CallerLogger.w("$M_ADAS_IMPL$TAG", "onUpgradeStateInfo : upgrade state info is null") - } + } // override fun onSSHResult(info: com.zhidao.adas.client.ssh.SSHResult?) { diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/MoGoHmiFragment.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/MoGoHmiFragment.kt index cb0591ecf2..715a543bc5 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/MoGoHmiFragment.kt +++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/MoGoHmiFragment.kt @@ -950,60 +950,6 @@ class MoGoHmiFragment : MvpFragment(), HmiBuildConfig.isShowSnBindingView = isOpen } - /** - * 展示工控机下载、升级状态信息 - * @param upgradeMode 升级模式(提示升级、静默升级) - * @param downloadStatus 下载状态 - * @param currentProgress 当前已经下载包体大小 - * @param totalProgress 下载包体总大小 - * @param downloadVersion 下载版本 - * @param upgradeStatus 升级状态 - */ - override fun showAdUpgradeStatus( - upgradeMode: Int, - downloadStatus: Int, - currentProgress: Int, - totalProgress: Int, - downloadVersion: String, - upgradeStatus: Int - ) { - ThreadUtils.runOnUiThread { - val tipsView = upgradeTipsView?.invoke() - //如果工控机处于“下载中”、“可升级(下载完成)”、“升级中”、“升级失败”状态时,工具箱入口显示红色角标 - if (AdUpgradeStateHelper.showUpgradeTips(downloadStatus, upgradeStatus)) { - if (HmiBuildConfig.isShowUpgradeTipsView) { - viewUpgradeTips?.visibility = View.VISIBLE - } else { - tipsView?.let { - it.visibility = View.VISIBLE - } - } - } else { - viewUpgradeTips?.visibility = View.GONE - tipsView?.let { - it.visibility = View.GONE - } - } - //将状态同步到工具箱 - toolsView?.showAdUpgradeStatus( - upgradeMode, - downloadStatus, - currentProgress, - totalProgress, - downloadVersion, - upgradeStatus - ) - //将状态同步到调试窗 - mDebugSettingView?.setAdUpgradeInfo( - upgradeMode, - downloadStatus, - currentProgress, - totalProgress, - downloadVersion, - upgradeStatus) - } - - } /** * 工控机监控节点上报 diff --git a/core/mogo-core-function-api/src/main/java/com/mogo/eagle/core/function/api/hmi/warning/IMoGoWaringProvider.kt b/core/mogo-core-function-api/src/main/java/com/mogo/eagle/core/function/api/hmi/warning/IMoGoWaringProvider.kt index f25f2667e6..10c90b297a 100644 --- a/core/mogo-core-function-api/src/main/java/com/mogo/eagle/core/function/api/hmi/warning/IMoGoWaringProvider.kt +++ b/core/mogo-core-function-api/src/main/java/com/mogo/eagle/core/function/api/hmi/warning/IMoGoWaringProvider.kt @@ -203,17 +203,6 @@ interface IMoGoWaringProvider : IMoGoHmiViewProxy { */ fun showModifyBindingcarDialog() - /** - * 展示工控机下载、升级状态信息 - * @param upgradeMode 升级模式(提示升级、静默升级) - * @param downloadStatus 下载状态 - * @param currentProgress 当前已经下载包体大小 - * @param totalProgress 下载包体总大小 - * @param downloadVersion 下载版本 - * @param upgradeStatus 升级状态 - */ - fun showAdUpgradeStatus(upgradeMode: Int, downloadStatus: Int, currentProgress: Int, totalProgress: Int, downloadVersion: String, upgradeStatus: Int) - /** *注册工控机升级提示圆点View的回调 * @param 提示圆点View diff --git a/core/mogo-core-function-call/src/main/java/com/mogo/eagle/core/function/call/hmi/CallerHmiManager.kt b/core/mogo-core-function-call/src/main/java/com/mogo/eagle/core/function/call/hmi/CallerHmiManager.kt index 49ab0d6a51..a9b553df96 100644 --- a/core/mogo-core-function-call/src/main/java/com/mogo/eagle/core/function/call/hmi/CallerHmiManager.kt +++ b/core/mogo-core-function-call/src/main/java/com/mogo/eagle/core/function/call/hmi/CallerHmiManager.kt @@ -279,20 +279,6 @@ object CallerHmiManager : CallerBase() { waringProviderApi?.hideToolsView() } - /** - * 展示工控机下载、升级状态信息 - * @param upgradeMode 升级模式(提示升级、静默升级) - * @param downloadStatus 下载状态 - * @param currentProgress 当前已经下载包体大小 - * @param totalProgress 下载包体总大小 - * @param downloadVersion 下载版本 - * @param upgradeStatus 升级状态 - */ - fun showAdUpgradeStatus(upgradeMode : Int, downloadStatus : Int,currentProgress : Int,totalProgress : Int - ,downloadVersion : String,upgradeStatus : Int){ - waringProviderApi?.showAdUpgradeStatus(upgradeMode,downloadStatus, currentProgress, totalProgress, downloadVersion, upgradeStatus) - } - /** *注册工控机升级提示圆点View的回调 * @param 提示圆点View