[6.5.0] fix bug of roam

This commit is contained in:
EmArrow
2024-07-03 20:18:55 +08:00
parent de4d758930
commit 3d0c70cb59
18 changed files with 81 additions and 91 deletions

View File

@@ -1,5 +1,6 @@
package com.mogo.eagle.core.function.call.map
import android.util.Log
import com.mogo.eagle.core.function.api.map.roma.IMoGoAiCloudIdentifyDataListener
import com.mogo.eagle.core.function.call.base.CallerBase
import mogo.yycp.api.proto.SocketDownData
@@ -7,14 +8,15 @@ import mogo.yycp.api.proto.SocketDownData
object CallerMapAiCloudDataManager : CallerBase<IMoGoAiCloudIdentifyDataListener>() {
fun invokeResponse(requestStatus: Boolean, errorMsg: String? = null) {
val tag = CallerMapIdentifyManager.roma.first
val tag = CallerMapIdentifyManager.roam.first
Log.i("emArrow","invokeResponse tag:$tag , status:$requestStatus , errorMsg:${errorMsg?:""}")
if(tag.isNotEmpty() && M_LISTENERS.containsKey(tag)){
M_LISTENERS[tag]?.response(requestStatus, errorMsg)
}
}
fun invokeAiIdentifyData(obj: SocketDownData.SocketDownDataProto?){
val tag = CallerMapIdentifyManager.roma.first
val tag = CallerMapIdentifyManager.roam.first
if(tag.isNotEmpty() && M_LISTENERS.containsKey(tag)){
M_LISTENERS[tag]?.onAiIdentifyData(obj)
}

View File

@@ -3,19 +3,21 @@ package com.mogo.eagle.core.function.call.map
import com.alibaba.android.arouter.launcher.ARouter
import com.mogo.eagle.core.data.constants.MogoServicePaths
import com.mogo.eagle.core.function.api.map.roma.IMogoRoma
import com.mogo.eagle.core.utilcode.util.ToastUtils
object CallerMapIdentifyManager {
@Volatile
var roma = Pair("", false)
var roam = Pair("", false)
set(value) {
field = value
}
private val romaApi: IMogoRoma
private val roamApi: IMogoRoma
get() = ARouter.getInstance().build(MogoServicePaths.PATH_MAP_BIZ)
.navigation() as IMogoRoma
fun romaTrigger(romaStatus: Boolean) {
romaApi.trigger(romaStatus)
fun romaTrigger(roamStatus: Boolean) {
roamApi.trigger(roamStatus)
}
}

View File

@@ -26,14 +26,14 @@ object CallerMsgBoxManager {
*/
fun saveMsgBox(bean: MsgBoxBean) {
CallerTrace.write(TAG,bean)
providerApi?.saveMsg(bean) //todo emArrow test
providerApi?.saveMsg(bean)
}
/**
* 存储含有pb的数据到消息盒子(区别与上述方法中的trace write)
*/
fun saveMsgBoxHasPB(bean: MsgBoxBean){
providerApi?.saveMsg(bean) //todo emArrow test
providerApi?.saveMsg(bean)
}
/**