Merge branch 'dev_robotaxi-d-app-module_2130_221116_2.13.0' into 'test_robotaxi-d-app-module_2130_221116_2.13.0.1'

Dev robotaxi d app module 2130 221116 2.13.0

See merge request zhjt/AndroidApp/MoGoEagleEye!383
This commit is contained in:
wangmingjun
2022-12-05 03:41:12 +00:00
41 changed files with 328 additions and 154 deletions

View File

@@ -36,14 +36,14 @@ if (!isAndroidTestBuild()) {
apply plugin: 'apm-plugin'
}
if (!isAndroidTestBuild()) {
apply plugin: 'bytex.threadOpt'
thread_opt {
enable !isReleaseBuild
enableInDebug !isReleaseBuild
logLevel "DEBUG"
}
}
//if (!isAndroidTestBuild()) {
// apply plugin: 'bytex.threadOpt'
// thread_opt {
// enable !isReleaseBuild
// enableInDebug !isReleaseBuild
// logLevel "DEBUG"
// }
//}
if (!isAndroidTestBuild()) {
apply plugin: 'LancetX'

View File

@@ -48,4 +48,15 @@ class LeakCanaryCrashFix {
t.printStackTrace()
}
}
@Insert
@TargetClass("leakcanary.internal.activity.db.Io\$execute\$2")
@TargetMethod(methodName = "run")
fun proxyRun() {
try {
Origin.callVoid()
} catch (t: Throwable) {
t.printStackTrace()
}
}
}

View File

@@ -79,7 +79,6 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
if (ProcessUtils.isMainProcess(context)) {
initGDLoc()
initHttpDns()
initCloudClientConfig()
}
return true
}
@@ -110,8 +109,10 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_SELF_INNOVATE
// 设置是否输出日志
clientConfig.isShowDebugLog = true
// 使用中台长链接
clientConfig.isUseOriginSocket = true
// 设置是否输出网络日志
clientConfig.isShowNetDebugLog = true //todo test em arrow
clientConfig.isShowNetDebugLog = false
// 设置是否是直播推流的主播
clientConfig.isAnchor = true
when (DebugConfig.getCarMachineType()) {
@@ -203,7 +204,10 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
clientConfig.token = token
// 由于存在token过期问题在更新后会回调至此处增加二次判定
if (!gotToken) {
CallerLogger.d(SceneConstant.M_MAIN + TAG, "onTokenGot token : $token , sn :$sn")
CallerLogger.d(
SceneConstant.M_MAIN + TAG,
"onTokenGot token : $token , sn :$sn"
)
CallerCloudListenerManager.invokeCloudTokenGot(token, sn)
// 异步初始化NetConfig
asyncInit()
@@ -313,7 +317,7 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
)
override fun onConnectFailure() {
CallerLogger.d(SceneConstant.M_MAIN + TAG, "socket-onConnectFailure")
MogoStatusManager.getInstance().setCloudSocketMode(TAG,false)
MogoStatusManager.getInstance().setCloudSocketMode(TAG, false)
}
@ChainLog(
@@ -326,7 +330,7 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
)
override fun onConnectSuccess() {
CallerLogger.d(SceneConstant.M_MAIN + TAG, "socket-onConnectSuccess")
MogoStatusManager.getInstance().setCloudSocketMode(TAG,true)
MogoStatusManager.getInstance().setCloudSocketMode(TAG, true)
}
@ChainLog(
@@ -339,7 +343,7 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
)
override fun onConnectLost() {
CallerLogger.d(SceneConstant.M_MAIN + TAG, "socket-onConnectLost")
MogoStatusManager.getInstance().setCloudSocketMode(TAG,false)
MogoStatusManager.getInstance().setCloudSocketMode(TAG, false)
}
@ChainLog(
@@ -364,10 +368,4 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
.init(context, DebugConfig.getSocketAppId(), lat, lon)
}
private fun initCloudClientConfig() {
// 使用旧Socket链路 true = 旧链路false = 新链路
if (DebugConfig.getProductFlavor() == "fPadLenovoOchTaxi" || DebugConfig.getProductFlavor() == "fPadLenovoOchBus" || DebugConfig.getProductFlavor() == "fPadLenovoOchTaxiPassenger" || DebugConfig.getProductFlavor() == "fPadLenovoOchBusPassenger") {
clientConfig.isUseOriginSocket = true
}
}
}

View File

@@ -34,7 +34,7 @@ buildscript {
classpath "com.mogo.cloud:hook:${HOOK_LOG_VERSION}"
classpath "com.mogo.cloud:bizconfig:${BIZCONFIG_VERSION}"
classpath 'com.volcengine:apm_insight_plugin:1.4.1'
classpath "com.mogo.thread.opt:plg:${THREAD_OPT_VERSION}"
// classpath "com.mogo.thread.opt:plg:${THREAD_OPT_VERSION}"
classpath 'com.mogo.cloud:systrace:1.0.1'
classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.18'
classpath 'com.mogo.sticky:service:1.0.8'

View File

@@ -17,6 +17,7 @@ import com.google.android.flexbox.FlexboxLayout
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
import com.mogo.eagle.core.data.app.AppConfigInfo
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
import com.mogo.eagle.core.data.msgbox.MsgCategory
import com.mogo.eagle.core.data.msgbox.RecordBagMsg
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotCarStateListener
import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotCarStatusListenerManager
@@ -275,14 +276,20 @@ class PassiveBadCaseWindow constructor(activity: Activity) : View.OnTouchListene
mInViewY = motionEvent.y
// 获取相对屏幕的坐标,即以屏幕左上角为原点
mDownInScreenX = motionEvent.rawX
mDownInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
// mDownInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
// mInScreenX = motionEvent.rawX
// mInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
mDownInScreenY = motionEvent.rawY
mInScreenX = motionEvent.rawX
mInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
mInScreenY = motionEvent.rawY
}
MotionEvent.ACTION_MOVE -> {
// 更新浮动窗口位置参数
mInScreenX = motionEvent.rawX
mInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
// mInScreenY = motionEvent.rawY - BarUtils.getStatusBarHeight()
mInScreenY = motionEvent.rawY
mWindowParams!!.x = (mInScreenX - mInViewX).toInt()
mWindowParams!!.y = (mInScreenY - mInViewY).toInt()
// 手指移动的时候更新小悬浮窗的位置
@@ -298,7 +305,7 @@ class PassiveBadCaseWindow constructor(activity: Activity) : View.OnTouchListene
// 默认固定位置,靠屏幕右边缘的中间
mWindowManager!!.defaultDisplay.getMetrics(metrics)
mWindowParams!!.x = metrics.widthPixels
mWindowParams!!.y = metrics.heightPixels / 2 - BarUtils.getStatusBarHeight()-350
mWindowParams!!.y = metrics.heightPixels - BarUtils.getStatusBarHeight()-950
mWindowManager!!.addView(mFloatLayout, mWindowParams)
}

View File

@@ -257,10 +257,12 @@ class MoGoHmiFragment : MvpFragment<MoGoHmiContract.View?, HmiPresenter?>(),
viewDriverMsgBoxList.visibility = View.VISIBLE
viewDriverMsgBoxList.notifyData()
viewDriverMsgBoxBubble.visibility = View.GONE
viewDriverMsgBoxBubble.isShowData(false)
CallerHmiManager.updateDriverMsgBoxTipView(false)
}else{
viewDriverMsgBoxList.visibility = View.GONE
viewDriverMsgBoxBubble.visibility = View.VISIBLE
viewDriverMsgBoxBubble.isShowData(true)
}
}
@@ -269,9 +271,12 @@ class MoGoHmiFragment : MvpFragment<MoGoHmiContract.View?, HmiPresenter?>(),
viewPassengerMsgBoxList.visibility = View.VISIBLE
viewPassengerMsgBoxBubble.visibility = View.GONE
viewPassengerMsgBoxList.notifyData()
viewPassengerMsgBoxBubble.isShowData(false)
CallerHmiManager.updatePassengerMsgBoxTipView(false)
}else{
viewPassengerMsgBoxList.visibility = View.GONE
viewPassengerMsgBoxBubble.visibility = View.VISIBLE
viewPassengerMsgBoxBubble.isShowData(true)
}
}
@@ -451,6 +456,10 @@ class MoGoHmiFragment : MvpFragment<MoGoHmiContract.View?, HmiPresenter?>(),
statusBarView?.updateRightView(insert, tag, viewGroup)
}
override fun updateStatusBarDownloadView(insert: Boolean, tag: String, progress: Int) {
statusBarView?.updateProgressView(insert, tag, progress)
}
override fun updateDriverMsgBoxTipView(show: Boolean) {
if(show){
MsgBoxTipView.visibility = View.VISIBLE
@@ -459,6 +468,14 @@ class MoGoHmiFragment : MvpFragment<MoGoHmiContract.View?, HmiPresenter?>(),
}
}
override fun updatePassengerMsgBoxTipView(show: Boolean) {
if(show){
MsgBoxPTipView.visibility = View.VISIBLE
}else{
MsgBoxPTipView.visibility = View.GONE
}
}
/**
* 设置 红绿灯 代理View
*/

View File

@@ -46,6 +46,7 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
private val TAG = "DriverMsgBoxBubbleView"
private val dataList :ArrayList<MsgBoxBean> = ArrayList()
private var isShowData = true
private fun initView() {
val linearLayoutManager = LinearLayoutManager(context)
@@ -65,10 +66,16 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
rvBubbleList.layoutManager = linearLayoutManager
}
/**
* 是否展示接收消息,消息盒子打开状态下不再展示气泡消息
* @param show true 展示false 不展示
*/
fun isShowData(show: Boolean){
isShowData = show
}
override fun onDataChanged(category: MsgCategory, msgBoxBean: MsgBoxBean) {
UiThreadHandler.post {
CallerHmiManager.updateDriverMsgBoxTipView(true)
when (category) {
MsgCategory.NOTICE -> {
MsgBoxConfig.noticeList.add(msgBoxBean)
@@ -80,13 +87,16 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
MsgBoxConfig.recordBagList.add(msgBoxBean)
}
}
if(category == MsgCategory.RECORD_BAG){
//弹出被动录包弹窗
CallerDevaToolsManager.onReceiveBadCaseRecord(msgBoxBean,context as Activity,true)
}else{
rvBubbleList.visibility = View.VISIBLE
dataList.add(msgBoxBean)
driverMsgBoxBubbleAdapter?.setData(dataList)
if(isShowData){
CallerHmiManager.updateDriverMsgBoxTipView(true)
if(category == MsgCategory.RECORD_BAG){
//弹出被动录包弹窗
CallerDevaToolsManager.onReceiveBadCaseRecord(msgBoxBean,context as Activity,true)
}else{
rvBubbleList.visibility = View.VISIBLE
dataList.add(msgBoxBean)
driverMsgBoxBubbleAdapter?.setData(dataList)
}
}
}
}
@@ -105,12 +115,4 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
}
}
// var i = 0
//
// fun setData(){
// val one = MsgBoxBean(MsgBoxType.OPERATION, OperationMsg(System.currentTimeMillis(),"测试"+i++))
// dataList.add(one)
// driverMsgBoxBubbleAdapter?.setData(dataList)
// }
}

View File

@@ -7,13 +7,7 @@ import android.view.LayoutInflater
import android.view.View
import androidx.constraintlayout.widget.ConstraintLayout
import androidx.recyclerview.widget.LinearLayoutManager
import com.mogo.eagle.core.data.enums.EventTypeEnum
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
import com.mogo.eagle.core.data.msgbox.MsgBoxType
import com.mogo.eagle.core.data.msgbox.OperationMsg
import com.mogo.eagle.core.data.msgbox.RecordBagMsg
import com.mogo.eagle.core.data.notice.NoticeNormalData
import com.mogo.eagle.core.data.report.ReportEntity
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
import com.mogo.eagle.core.function.hmi.R
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.DriverMsgBoxListAdapter
@@ -48,14 +42,10 @@ class DriverMsgBoxListView @JvmOverloads constructor(
//获取通知消息列表
noticeList= CallerMsgBoxManager.getCachedNotifyData() as ArrayList<MsgBoxBean>?
noticeList?.reversed()
//获取车辆系统信息列表
ipcReportList = CallerMsgBoxManager.getCachedSysInfoData() as ArrayList<MsgBoxBean>?
ipcReportList?.reversed()
//获取录包信息列表
badCaseList = CallerMsgBoxManager.getCachedRecordBagData() as ArrayList<MsgBoxBean>?
badCaseList?.reversed()
//通知
tvMsgNotice.setOnClickListener {
tvMsgNotice.setTextColor(resources.getColor(R.color.msg_box_title_color))
@@ -118,6 +108,7 @@ class DriverMsgBoxListView @JvmOverloads constructor(
val localSysInfoList = MsgBoxConfig.systemInfoList.reversed()
ipcReportList?.addAll(0,localSysInfoList)
val localRecordList = MsgBoxConfig.recordBagList.reversed()
badCaseList?.addAll(0,localRecordList)
//获取当前Tab选择

View File

@@ -2,9 +2,7 @@ package com.mogo.eagle.core.function.hmi.ui.msgbox
import android.app.Activity
import android.content.Context
import android.graphics.PixelFormat
import android.util.AttributeSet
import android.util.DisplayMetrics
import android.view.*
import androidx.constraintlayout.widget.ConstraintLayout
import androidx.recyclerview.widget.LinearLayoutManager
@@ -12,14 +10,13 @@ import com.mogo.eagle.core.data.config.FunctionBuildConfig
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
import com.mogo.eagle.core.data.msgbox.MsgBoxType
import com.mogo.eagle.core.data.msgbox.MsgCategory
import com.mogo.eagle.core.data.msgbox.OperationMsg
import com.mogo.eagle.core.function.api.msgbox.IMsgBoxListener
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
import com.mogo.eagle.core.function.hmi.R
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.PassengerMsgBoxBubbleAdapter
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
import com.mogo.eagle.core.utilcode.util.BarUtils
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
import kotlinx.android.synthetic.main.layout_passenger_msg_box_bubble.view.*
@@ -36,7 +33,9 @@ class PassengerMsgBoxBubbleView @JvmOverloads constructor(
private val TAG = "PassengerMsgBoxBubbleView"
private val dataList :ArrayList<MsgBoxBean> = ArrayList()
var passengerMsgBoxBubbleAdapter: PassengerMsgBoxBubbleAdapter ?= null
private var passengerMsgBoxBubbleAdapter: PassengerMsgBoxBubbleAdapter ?= null
private var isShowData = true
init {
LayoutInflater.from(context).inflate(R.layout.layout_passenger_msg_box_bubble, this, true)
initView()
@@ -45,21 +44,30 @@ class PassengerMsgBoxBubbleView @JvmOverloads constructor(
private fun initView(){
val linearLayoutManager = LinearLayoutManager(context)
linearLayoutManager.orientation = LinearLayoutManager.VERTICAL
// linearLayoutManager.stackFromEnd = true
// linearLayoutManager.reverseLayout = true
passengerMsgBoxBubbleAdapter = PassengerMsgBoxBubbleAdapter(context as Activity)
rvPassengerBubbleList.adapter = passengerMsgBoxBubbleAdapter
rvPassengerBubbleList.layoutManager = linearLayoutManager
}
/**
* 是否展示接收消息,消息盒子打开状态下不再展示气泡消息
* @param show true 展示false 不展示
*/
fun isShowData(show: Boolean){
isShowData = show
}
override fun onDataChanged(category: MsgCategory, msgBoxList: MsgBoxBean) {
UiThreadHandler.post {
if(category == MsgCategory.NOTICE){
if(msgBoxList.type == MsgBoxType.NOTICE || msgBoxList.type == MsgBoxType.V2X
|| msgBoxList.type == MsgBoxType.OBU){
dataList.add(msgBoxList)
passengerMsgBoxBubbleAdapter?.setData(dataList)
MsgBoxConfig.noticeList.add(msgBoxList)
if(isShowData){
CallerHmiManager.updatePassengerMsgBoxTipView(true)
dataList.add(msgBoxList)
passengerMsgBoxBubbleAdapter?.setData(dataList)
}
}
}
}

View File

@@ -10,7 +10,6 @@ import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import com.mogo.eagle.core.data.enums.EventTypeEnum
import com.mogo.eagle.core.data.msgbox.*
import com.mogo.eagle.core.data.notice.NoticeNormalData
import com.mogo.eagle.core.data.report.ReportEntity
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotManager
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager

View File

@@ -107,6 +107,7 @@ class DriverMsgBoxListAdapter(private val activity: Activity) : RecyclerView.Ada
}
holder.tvReportTimeNormal.text = "时间:${TimeUtils.millis2String(it[position].timestamp)}"
holder.tvReportTimeOpen.text = "时间:${TimeUtils.millis2String(it[position].timestamp)}"
holder.tvReportTime.text =TimeUtils.millis2String(it[position].timestamp,getHourMinFormat())
var resultStr = "类型:"
for (result in reportEntity.resultList){
resultStr = "${resultStr}${CallerAutoPilotManager.getReportResultDesc(result)}"
@@ -114,6 +115,11 @@ class DriverMsgBoxListAdapter(private val activity: Activity) : RecyclerView.Ada
holder.tvReportTypeNormal.text = resultStr
holder.tvReportTypeOpen.text = resultStr
holder.tvReportReasonOpen.text = "原因:${reportEntity.msg}"
var actionStr = ""
for (action in reportEntity.actionsList){
actionStr = "${actionStr}${CallerAutoPilotManager.getReportActionDesc(action)}"
}
holder.tvReportActionOpen.text = "建议操作:$actionStr"
holder.tvStatusSelect.setOnClickListener {
if(holder.tvReportLevelNormal.isVisible){
holder.tvStatusSelect.setCompoundDrawablesWithIntrinsicBounds(getDrawable(R.drawable.icon_msg_close),null,null,null)
@@ -127,6 +133,7 @@ class DriverMsgBoxListAdapter(private val activity: Activity) : RecyclerView.Ada
holder.tvReportTimeOpen.visibility = View.VISIBLE
holder.tvReportTypeOpen.visibility = View.VISIBLE
holder.tvReportReasonOpen.visibility = View.VISIBLE
holder.tvReportActionOpen.visibility = View.VISIBLE
}else{
holder.tvStatusSelect.setCompoundDrawablesWithIntrinsicBounds(getDrawable(R.drawable.icon_msg_open),null,null,null)
holder.ivReportImageNormal.visibility = View.VISIBLE
@@ -139,6 +146,7 @@ class DriverMsgBoxListAdapter(private val activity: Activity) : RecyclerView.Ada
holder.tvReportTimeOpen.visibility = View.GONE
holder.tvReportTypeOpen.visibility = View.GONE
holder.tvReportReasonOpen.visibility = View.GONE
holder.tvReportActionOpen.visibility = View.GONE
}
}
}
@@ -243,11 +251,13 @@ class DriverMsgBoxListAdapter(private val activity: Activity) : RecyclerView.Ada
var tvReportTimeNormal: TextView = itemView.findViewById(R.id.tvReportTimeNormal)
var tvReportTypeNormal: TextView = itemView.findViewById(R.id.tvReportTypeNormal)
var tvStatusSelect: TextView = itemView.findViewById(R.id.tvStatusSelect)
var tvReportTime: TextView = itemView.findViewById(R.id.tvReportTime)
var ivReportImageOpen: ImageView = itemView.findViewById(R.id.ivReportImageOpen)
var tvReportLevelOpen: TextView = itemView.findViewById(R.id.tvReportLevelOpen)
var tvReportTimeOpen: TextView = itemView.findViewById(R.id.tvReportTimeOpen)
var tvReportTypeOpen: TextView = itemView.findViewById(R.id.tvReportTypeOpen)
var tvReportReasonOpen: TextView = itemView.findViewById(R.id.tvReportReasonOpen)
var tvReportActionOpen: TextView = itemView.findViewById(R.id.tvReportActionOpen)
}
//运营平台

View File

@@ -78,6 +78,7 @@ import com.mogo.map.MogoMapUIController
import com.mogo.map.uicontroller.VisualAngleMode
import com.mogo.map.uicontroller.VisualAngleMode.*
import com.mogo.eagle.core.function.business.routeoverlay.*
import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager
import com.mogo.eagle.core.function.v2x.vip.VipCarManager
import com.zhidao.easysocket.utils.L
import com.zhidao.support.adas.high.other.permission.BackgrounderPermission
@@ -1651,6 +1652,20 @@ class DebugSettingView @JvmOverloads constructor(
*/
@SuppressLint("SetTextI18n")
private fun drawAppInfo() {
when {
AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode) -> {// 司机端
AppConfigInfo.isDriver = true
AppConfigInfo.isConnectedNetty = CallerTelematicManager.getServerStarted()
}
AppIdentityModeUtils.isPassenger(FunctionBuildConfig.appIdentityMode) -> {
AppConfigInfo.isDriver = false
AppConfigInfo.isConnectedNetty = CallerTelematicManager.getClientConnStatus()
AppConfigInfo.serverSn = CallerTelematicManager.getServerToken()
}
else -> {
}
}
/**
* 设备绑定关系
*/

View File

@@ -70,6 +70,16 @@ class StatusBarView @JvmOverloads constructor(
}
}
fun updateProgressView(insert: Boolean, tag: String, progress: Int) {
if (insert) {
viewProgressTv.visibility = VISIBLE
viewProgressTv.text = "$progress%"
} else {
viewProgressTv.visibility = GONE
}
}
private fun setTextColor(color: Int) {
viewTextClock.setTextColor(color)
viewStatusBarTag.setTextColor(color)

View File

@@ -77,43 +77,6 @@ class SystemVersionView @JvmOverloads constructor(
// "",
// "1"
// )
// val builder = NotificationCompat.Builder(context)
// builder.setSmallIcon(R.mipmap.icon1001)
// builder.setContentTitle("下载")
// builder.setContentText("正在下载")
// val manager: NotificationManager? = context.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager?
//
// CallerDevaToolsUpgradeListenerManager.registerDevaToolsUpgradeListener(TAG,
// object : IMogoDevaToolsUpgradeListener {
// override fun onStart(url: String?) {
//// Log.d("Package-DownLoad", " SystemVersionView onStart --------> ")
// }
//
// override fun onPause(url: String?) {
//
// }
//
// override fun onProgress(url: String?, length: Int) {
//// Log.d("Package-DownLoad", " SystemVersionView onProgress length = $length")
// builder.setProgress(100, length,false)
// manager?.notify(0x3,builder.build())
// //下载进度提示
// builder.setContentText("已下载" + length + "%")
// }
//
// override fun onFinished(url: String?) {
//// Log.d("Package-DownLoad", " SystemVersionView onFinished ------> ")
// builder.setContentText("已下载" + 100 + "%")
// UiThreadHandler.postDelayed({
// manager?.cancel(0x3)
// }, 500L)
// }
//
// override fun onError(url: String?, errorMsg: String?) {
//// Log.d("Package-DownLoad", " errorMsg = $errorMsg")
// }
// })
}
//工控机版本视图点击事件

View File

@@ -26,6 +26,7 @@ import com.mogo.eagle.core.function.api.devatools.IMogoDevaToolsUpgradeListener;
import com.mogo.eagle.core.function.call.bindingcar.CallerBindingcarManager;
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager;
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsUpgradeListenerManager;
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager;
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager;
import com.mogo.eagle.core.function.hmi.R;
import com.mogo.eagle.core.function.msgbox.db.MsgBoxDb;
@@ -149,6 +150,7 @@ public abstract class MainMoGoApplication extends AbsMogoApplication {
manager.notify(0x3, builder.build());
//下载进度提示
builder.setContentText("已下载" + length + "%");
CallerHmiManager.INSTANCE.updateStatusBarDownloadView(true, "download", length);
}
@Override
@@ -158,6 +160,7 @@ public abstract class MainMoGoApplication extends AbsMogoApplication {
@Override
public void run() {
manager.cancel(0x3);
CallerHmiManager.INSTANCE.updateStatusBarDownloadView(false, "download", 100);
}
}, 1000);
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 122 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 504 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<corners android:radius="24dp"/>
<solid android:color="#0056FF" />
</shape>

View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<gradient
android:startColor="#31486E"
android:endColor="#223554"
android:type="linear"
android:angle="270"
/>
<size android:height="750px"
android:width="650px"
/>
</shape>

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="oval"
android:useLevel="false">
<solid android:color="#FFEE2A2A" />
<size
android:width="20px"
android:height="20px" />
</shape>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/icon_msg_box_p" android:state_checked="false" />
<item android:drawable="@drawable/icon_msg_box_p" android:state_checked="true" />
</selector>

View File

@@ -182,7 +182,7 @@
app:layout_goneMarginTop="40dp"
tools:visibility="gone" />
<!--消息盒子选择入口-->
<!--消息盒子司机端选择入口-->
<CheckBox
android:id="@+id/cbMsgBoxDriver"
android:layout_width="150dp"
@@ -195,20 +195,7 @@
android:background="@drawable/selector_msg_box"
android:visibility="gone"
/>
<CheckBox
android:id="@+id/cbMsgBoxPassenger"
android:layout_width="150dp"
android:layout_height="150dp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginStart="300dp"
android:layout_marginBottom="30px"
android:button="@null"
android:background="@drawable/selector_msg_box"
android:visibility="gone"
/>
<!--司机端消息提示-->
<View
android:id="@+id/MsgBoxTipView"
android:layout_width="8dp"
@@ -222,6 +209,34 @@
android:visibility="gone"
/>
<!--消息盒子乘客端选择入口-->
<CheckBox
android:id="@+id/cbMsgBoxPassenger"
android:layout_width="100dp"
android:layout_height="100dp"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginStart="320dp"
android:layout_marginBottom="50dp"
android:button="@null"
android:background="@drawable/selector_msg_box_p"
android:visibility="gone"
/>
<!--乘客端消息提示-->
<View
android:id="@+id/MsgBoxPTipView"
android:layout_width="15dp"
android:layout_height="15dp"
android:background="@drawable/version_upgrade_tips_background"
android:translationZ="30dp"
app:layout_constraintCircle="@id/cbMsgBoxPassenger"
app:layout_constraintCircleAngle="40"
app:layout_constraintCircleRadius="50dp"
tools:ignore="MissingConstraints"
android:visibility="gone"
/>
<com.mogo.eagle.core.function.hmi.ui.msgbox.DriverMsgBoxListView
android:id="@+id/viewDriverMsgBoxList"
android:layout_width="864px"
@@ -249,6 +264,7 @@
app:layout_constraintBottom_toTopOf="@id/cbMsgBoxPassenger"
app:layout_constraintLeft_toLeftOf="@id/cbMsgBoxPassenger"
app:layout_constraintRight_toRightOf="@id/cbMsgBoxPassenger"
android:layout_marginBottom="20dp"
android:visibility="gone"
/>
@@ -259,6 +275,7 @@
app:layout_constraintBottom_toTopOf="@id/cbMsgBoxPassenger"
app:layout_constraintLeft_toLeftOf="@id/cbMsgBoxPassenger"
app:layout_constraintRight_toRightOf="@id/cbMsgBoxPassenger"
android:layout_marginBottom="20dp"
android:visibility="gone"
/>

View File

@@ -4,7 +4,7 @@
android:layout_width="804px"
android:layout_height="160px"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#1B2966"
android:background="#1A2344"
app:roundLayoutRadius="24px"
android:layout_gravity="center_horizontal"
android:layout_marginStart="30px"
@@ -43,6 +43,7 @@
android:layout_height="wrap_content"
app:layout_constraintBottom_toBottomOf="@id/ivBadCaseImage"
app:layout_constraintLeft_toRightOf="@id/ivBadCaseImage"
android:layout_marginBottom="5px"
android:layout_marginStart="25px"
android:textColor="#B3FFFFFF"
android:textSize="30px"
@@ -56,7 +57,7 @@
app:layout_constraintTop_toTopOf="@id/tvRecordTip"
android:textColor="#80FFFFFF"
android:textSize="24px"
android:layout_marginEnd="15px"
android:layout_marginEnd="25px"
/>
<TextView
@@ -66,7 +67,9 @@
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="@id/tvBagRecordTime"
app:layout_constraintBottom_toBottomOf="@id/tvBagRecordTime"
android:layout_marginEnd="15px"
android:paddingEnd="25px"
android:paddingTop="10px"
android:paddingBottom="10px"
android:text="查看"
android:textColor="#FFFFFFFF"
android:textSize="30px"

View File

@@ -44,7 +44,7 @@
app:layout_constraintLeft_toLeftOf="@id/tvReportLevelNormal"
android:textColor="#B3FFFFFF"
android:textSize="28px"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
/>
<TextView
@@ -55,7 +55,7 @@
app:layout_constraintLeft_toLeftOf="@id/tvReportTimeNormal"
app:layout_constraintRight_toRightOf="@id/tvStatusSelect"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:layout_marginBottom="10px"
android:textColor="#B3FFFFFF"
android:gravity="start"
@@ -84,6 +84,18 @@
android:paddingBottom="5px"
/>
<TextView
android:id="@+id/tvReportTime"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintTop_toTopOf="@id/tvStatusSelect"
app:layout_constraintBottom_toBottomOf="@id/tvStatusSelect"
app:layout_constraintRight_toLeftOf="@id/tvStatusSelect"
android:layout_marginEnd="20px"
android:textColor="#80FFFFFF"
android:textSize="24px"
/>
<ImageView
android:id="@+id/ivReportImageOpen"
android:layout_width="44px"
@@ -114,7 +126,7 @@
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="@id/ivReportImageOpen"
app:layout_constraintLeft_toLeftOf="@id/ivReportImageOpen"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:textColor="#B3FFFFFF"
android:textSize="28px"
android:visibility="gone"
@@ -126,7 +138,7 @@
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="@id/tvReportTimeOpen"
app:layout_constraintLeft_toLeftOf="@id/tvReportTimeOpen"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:textColor="#B3FFFFFF"
android:textSize="28px"
android:visibility="gone"
@@ -139,9 +151,22 @@
app:layout_constraintTop_toBottomOf="@id/tvReportTypeOpen"
app:layout_constraintLeft_toLeftOf="@id/tvReportTypeOpen"
app:layout_constraintRight_toRightOf="@id/tvStatusSelect"
app:layout_constraintBottom_toBottomOf="parent"
android:gravity="start"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:textColor="#B3FFFFFF"
android:textSize="28px"
android:visibility="gone"
/>
<TextView
android:id="@+id/tvReportActionOpen"
android:layout_width="0dp"
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="@id/tvReportReasonOpen"
app:layout_constraintLeft_toLeftOf="@id/tvReportReasonOpen"
app:layout_constraintRight_toRightOf="@id/tvStatusSelect"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginTop="5px"
android:layout_marginBottom="10px"
android:textColor="#B3FFFFFF"
android:textSize="28px"

View File

@@ -29,7 +29,8 @@
android:id="@+id/tvOperationTitleNormal"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintTop_toTopOf="@id/ivOperationImageNormal"
app:layout_constraintTop_toTopOf="@id/tvOperationStatusSelect"
app:layout_constraintBottom_toBottomOf="@id/tvOperationStatusSelect"
app:layout_constraintLeft_toRightOf="@id/ivOperationImageNormal"
android:text="运营平台"
android:textColor="#FFFFFFFF"
@@ -44,7 +45,7 @@
app:layout_constraintTop_toBottomOf="@id/tvOperationTitleNormal"
app:layout_constraintLeft_toLeftOf="@id/tvOperationTitleNormal"
app:layout_constraintRight_toRightOf="@id/tvOperationStatusSelect"
android:layout_marginEnd="25px"
android:layout_marginTop="10px"
android:textColor="#B3FFFFFF"
android:gravity="start"
android:textSize="28px"
@@ -100,8 +101,8 @@
android:id="@+id/tvOperationTitleOpen"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:layout_constraintTop_toTopOf="@id/ivOperationImageOpen"
app:layout_constraintBottom_toBottomOf="@id/ivOperationImageOpen"
app:layout_constraintTop_toTopOf="@id/tvOperationStatusSelect"
app:layout_constraintBottom_toBottomOf="@id/tvOperationStatusSelect"
app:layout_constraintLeft_toRightOf="@id/ivOperationImageOpen"
android:text="运营平台"
android:textColor="#FFFFFFFF"
@@ -119,7 +120,7 @@
app:layout_constraintLeft_toLeftOf="@id/ivOperationImageOpen"
app:layout_constraintRight_toRightOf="@id/tvOperationStatusSelect"
android:gravity="start"
android:layout_marginTop="15px"
android:layout_marginTop="10px"
android:layout_marginBottom="15px"
android:textColor="#B3FFFFFF"
android:textSize="28px"

View File

@@ -37,10 +37,9 @@
android:layout_height="wrap_content"
app:layout_constraintLeft_toRightOf="@id/ivV2XImage"
app:layout_constraintRight_toRightOf="@id/tvV2XTime"
app:layout_constraintTop_toBottomOf="@id/tvV2XTime"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginStart="25px"
android:layout_marginBottom="25px"
android:textColor="#FFFFFFFF"
android:textSize="32px"
android:maxLines="1"

View File

@@ -42,7 +42,7 @@
app:layout_constraintTop_toTopOf="@id/tvBubbleOperationTitle"
app:layout_constraintBottom_toBottomOf="@id/tvBubbleOperationTitle"
app:layout_constraintRight_toRightOf="parent"
android:layout_marginEnd="20px"
android:layout_marginEnd="25px"
android:textColor="#80FFFFFF"
android:textSize="24px"
/>
@@ -54,7 +54,7 @@
app:layout_constraintLeft_toLeftOf="@id/tvBubbleOperationTitle"
app:layout_constraintRight_toRightOf="@id/tvBubbleOperationTime"
app:layout_constraintTop_toBottomOf="@id/tvBubbleOperationTitle"
android:layout_marginTop="20px"
android:layout_marginTop="10px"
android:gravity="start"
android:maxLines="2"
android:ellipsize="end"

View File

@@ -42,7 +42,7 @@
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="@id/tvBubbleReportTitle"
app:layout_constraintLeft_toLeftOf="@id/tvBubbleReportTitle"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:textColor="#B3FFFFFF"
android:textSize="28px"
/>
@@ -53,7 +53,7 @@
android:layout_height="wrap_content"
app:layout_constraintTop_toBottomOf="@id/tvBubbleReportTime"
app:layout_constraintLeft_toLeftOf="@id/tvBubbleReportTime"
android:layout_marginTop="10px"
android:layout_marginTop="5px"
android:textColor="#B3FFFFFF"
android:textSize="28px"
/>

View File

@@ -5,8 +5,8 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#465878"
app:roundLayoutRadius="24px"
android:layout_marginTop="10px"
android:layout_marginBottom="10px"
android:layout_marginTop="16px"
android:layout_marginBottom="16px"
>
<ImageView
@@ -32,6 +32,16 @@
app:layout_constraintBottom_toTopOf="@id/tvPassengerNoticeContent"
/>
<ImageView
android:layout_width="25px"
android:layout_height="23px"
app:layout_constraintTop_toTopOf="@id/tvPassengerNoticeTitle"
app:layout_constraintBottom_toBottomOf="@id/tvPassengerNoticeTitle"
app:layout_constraintLeft_toRightOf="@id/tvPassengerNoticeTitle"
android:layout_marginStart="10px"
android:src="@drawable/icon_msg_box_video"
/>
<TextView
android:id="@+id/tvPassengerNoticeContent"
android:layout_width="0dp"

View File

@@ -4,7 +4,9 @@
android:layout_height="160px"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#465878"
app:roundLayoutRadius="24px">
app:roundLayoutRadius="24px"
android:layout_marginTop="16px"
android:layout_marginBottom="16px">
<ImageView
android:id="@+id/ivPassengerV2XImage"

View File

@@ -10,8 +10,8 @@
android:id="@+id/rvBubbleList"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingTop="10px"
android:paddingBottom="10px"
android:paddingTop="15px"
android:paddingBottom="15px"
android:visibility="gone"
/>

View File

@@ -1,10 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="864px"
android:layout_height="746px"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#2E3868"
app:roundLayoutRadius="40px">
android:background="@drawable/bg_msg_box"
>
<TextView
android:id="@+id/tvMsgNotice"
@@ -86,4 +86,4 @@
app:layout_constraintRight_toRightOf="parent"
/>
</com.mogo.eagle.core.widget.RoundConstraintLayout>
</androidx.constraintlayout.widget.ConstraintLayout>

View File

@@ -1,10 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
<com.mogo.eagle.core.widget.RoundConstraintLayout
android:layout_width="650px"
android:layout_height="750px"
android:background="@drawable/bg_msg_box_list_p"
app:roundLayoutRadius="40px"
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:background="#31486E"
app:roundLayoutRadius="40px">
android:layout_marginBottom="16px">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/rvPassengerList"

View File

@@ -35,6 +35,19 @@
android:layout_gravity="center"
android:layout_marginStart="@dimen/dp_18" />
<TextView
android:id="@+id/viewProgressTv"
android:layout_width="@dimen/dp_96"
android:layout_height="@dimen/dp_50"
android:layout_gravity="center"
android:visibility="gone"
android:background="@drawable/app_download_bg"
android:layout_marginStart="@dimen/dp_20"
android:gravity="center"
android:drawableLeft="@drawable/icon_download_guide"
android:textColor="@color/background_debug"
android:textSize="@dimen/dp_20" />
<Space
android:layout_width="0dip"
android:layout_height="@dimen/dp_1"

View File

@@ -342,8 +342,12 @@ public class MapFragment extends MvpFragment<MapView, MapPresenter>
@Override
public void setIsDrawPointCloud(boolean isDrawPointCloud) {
// 是否绘制点云
PointCloudHelper.INSTANCE.setIsDrawPointCloud(isDrawPointCloud);
try {
// 是否绘制点云
PointCloudHelper.INSTANCE.setIsDrawPointCloud(isDrawPointCloud);
} catch (Exception e) {
e.printStackTrace();
}
}
/**

View File

@@ -296,5 +296,18 @@ interface IMoGoWaringProvider : IMoGoHmiViewProxy {
*/
fun updateStatusBarRightView(insert: Boolean, tag: String, viewGroup: ViewGroup)
/**
* 设置司机端消息盒子是否展示
*/
fun updateDriverMsgBoxTipView(show: Boolean)
/**
* 设置乘客端消息盒子是否展示
*/
fun updatePassengerMsgBoxTipView(show: Boolean)
/**
* 更新(添加/删除)下载进度
*/
fun updateStatusBarDownloadView(insert: Boolean, tag: String, progress: Int)
}

View File

@@ -476,10 +476,24 @@ object CallerHmiManager : CallerBase() {
}
/**
* 更新司机端消息盒子是否展示
* 设置司机端消息盒子是否展示
*/
fun updateDriverMsgBoxTipView(show: Boolean = false){
waringProviderApi?.updateDriverMsgBoxTipView(show)
}
/**
* 设置乘客端消息盒子是否展示
*/
fun updatePassengerMsgBoxTipView(show: Boolean = false){
waringProviderApi?.updatePassengerMsgBoxTipView(show)
}
/**
* 更新(添加/删除)状态栏右侧元素
*/
fun updateStatusBarDownloadView(insert: Boolean, tag: String, progress: Int) {
waringProviderApi?.updateStatusBarDownloadView(insert, tag, progress)
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View File

@@ -58,9 +58,9 @@ public class MogoServices implements IMogoIntentListener {
intent.addFlags(Intent.FLAG_INCLUDE_STOPPED_PACKAGES);
mContext.sendBroadcast(intent);
if (DebugConfig.isNeedUploadCoordinatesDurationInTime()) {
MoGoAiCloudRealTime.startRealTime(mContext, DebugConfig.getSocketAppId());
}
// if (DebugConfig.isNeedUploadCoordinatesDurationInTime()) {
// MoGoAiCloudRealTime.startRealTime(mContext, DebugConfig.getSocketAppId());
// }
}
private void registerMogoReceiver(Context context) {
@@ -105,9 +105,9 @@ public class MogoServices implements IMogoIntentListener {
public void destroy() {
CallerLogger.INSTANCE.d(M_OLD_OTHER + TAG, "MogoServices do nothings.");
if (DebugConfig.isNeedUploadCoordinatesDurationInTime()) {
MoGoAiCloudRealTime.stopRealTime();
}
// if (DebugConfig.isNeedUploadCoordinatesDurationInTime()) {
// MoGoAiCloudRealTime.stopRealTime();
// }
}
}