[6.2.0]录包工具修复点击查看可以多次打开上报弹窗

This commit is contained in:
xuxinchao
2023-11-22 19:43:19 +08:00
parent a6d624e381
commit 510578c097
4 changed files with 11 additions and 4 deletions

View File

@@ -237,7 +237,7 @@ internal object BadCaseManager : LifecycleEventObserver, IMoGoAutopilotRecordLis
MsgBoxBean(
MsgBoxType.RECORD, RecordBagMsg(
recordPanel.key, recordPanel.stat, recordPanel.id,
recordPanel.type, recordPanel.filename, recordPanel.note
recordPanel.type, recordPanel.filename, recordPanel.note,false
)
)
)

View File

@@ -529,6 +529,7 @@ class PassiveBadCaseWindow constructor(activity: Activity) : View.OnTouchListene
recordFileName = recordBagMsg.fileName
receiveTime = msgBoxBean.timestamp.toString()
stat = recordBagMsg.stat.toString()
recordBagMsg.isShow = true
}
fun setClickListener(clickListener: ClickListener) {

View File

@@ -24,6 +24,7 @@ import com.mogo.eagle.core.utilcode.mogo.glide.transform.GlideRoundedCornersTran
import com.mogo.eagle.core.utilcode.util.ResourceUtils.getDrawable
import com.mogo.eagle.core.utilcode.util.TimeUtils
import com.mogo.eagle.core.utilcode.util.TimeUtils.getHourMinFormat
import com.mogo.eagle.core.utilcode.util.ToastUtils
/**
* @author XuXinChao
@@ -130,9 +131,14 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
holder.tvBagRecordTime.text =
"时间:${TimeUtils.millis2String(it[position].timestamp)}"
val msgBoxBean = it[position]
val recordBagMsg = msgBoxBean.bean as RecordBagMsg
holder.tvRecordCheck.setOnClickListener {
//打开被动录包弹窗
CallerDevaToolsManager.onReceiveBadCaseRecord(msgBoxBean, activity, false)
if(recordBagMsg.isShow){
ToastUtils.showShort("当前录包上报面板已打开,请勿重复操作")
}else{
//打开被动录包弹窗
CallerDevaToolsManager.onReceiveBadCaseRecord(msgBoxBean, activity, false)
}
}
}
}

View File

@@ -2,4 +2,4 @@ package com.mogo.eagle.core.data.msgbox
import java.io.Serializable
data class RecordBagMsg(var key: Long, var stat: Int, var id: Int, var type: Int, var fileName: String, var note: String): Serializable
data class RecordBagMsg(var key: Long, var stat: Int, var id: Int, var type: Int, var fileName: String, var note: String,var isShow: Boolean): Serializable