Merge branch 'dev_minibus-d_230425_3.2.0' into merge320tomaster
@@ -32,6 +32,7 @@
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||
<uses-permission android:name="android.permission.KILL_BACKGROUND_PROCESSES" />
|
||||
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
||||
|
||||
<application>
|
||||
|
||||
@@ -69,8 +70,6 @@
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
<category android:name="android.intent.category.LAUNCHER_APP" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<!--调试用,暂时开启LAUNCHER这个属性-->
|
||||
<category android:name="android.intent.category.HOME" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<data
|
||||
@@ -180,5 +179,14 @@
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
</intent-filter>
|
||||
</receiver>
|
||||
|
||||
<receiver android:name="com.mogo.eagle.core.function.hmi.receiver.BootCompleteReceiver"
|
||||
android:enabled="true"
|
||||
android:exported="true">
|
||||
<intent-filter android:priority="1000">
|
||||
<action android:name="android.intent.action.BOOT_COMPLETED" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
</intent-filter>
|
||||
</receiver>
|
||||
</application>
|
||||
</manifest>
|
||||
@@ -0,0 +1,22 @@
|
||||
package com.mogo.eagle.core.function.hmi.receiver
|
||||
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import android.util.Log
|
||||
import com.mogo.eagle.core.utilcode.util.AppUtils
|
||||
|
||||
/**
|
||||
* 开机启动广播
|
||||
*/
|
||||
class BootCompleteReceiver : BroadcastReceiver() {
|
||||
val TAG = "BootCompleteReceiver"
|
||||
|
||||
override fun onReceive(context: Context, intent: Intent) {
|
||||
if (Intent.ACTION_BOOT_COMPLETED == intent.action) {
|
||||
Log.d(TAG, "ACTION_BOOT_COMPLETED")
|
||||
val packageName = AppUtils.getAppPackageName()
|
||||
AppUtils.launchApp(packageName)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -89,6 +89,6 @@ class V2XWarningBroadcastReceiver : BroadcastReceiver() {
|
||||
)
|
||||
)
|
||||
//预留调试入口
|
||||
CallerHmiManager.warningV2X(v2xType.toString(), alertContent, ttsContent)
|
||||
CallerHmiManager.warningV2X(v2xType.toString(), alertContent, ttsContent, isFromObu = false)
|
||||
}
|
||||
}
|
||||
@@ -96,25 +96,21 @@ class MoGoHmiProvider : IMoGoHmiProvider {
|
||||
* 不展示顶部弹窗,其它保留
|
||||
*/
|
||||
@Synchronized
|
||||
override fun warningV2X(
|
||||
v2xType: String,
|
||||
alertContent: CharSequence?,
|
||||
ttsContent: String?,
|
||||
listener: IMoGoWarningStatusListener?,
|
||||
direction: WarningDirectionEnum,
|
||||
expireTime: Long
|
||||
) {
|
||||
//30秒内同一个事件只出现一次 TODO 临时添加,后面宏宇统一在数据中心处理
|
||||
if (ttsMap.containsKey(v2xType)) {
|
||||
var oldTime = ttsMap[v2xType]
|
||||
var timeDiff = (System.currentTimeMillis() - oldTime!!) / 1000
|
||||
if (timeDiff < 30) {
|
||||
return
|
||||
override fun warningV2X(v2xType: String, alertContent: CharSequence?, ttsContent: String?, listener: IMoGoWarningStatusListener?, direction: WarningDirectionEnum, expireTime: Long, isFromObu: Boolean) {
|
||||
if (isFromObu) {
|
||||
// 修改: 只有来自obu的事件这样处理
|
||||
//30秒内同一个事件只出现一次 TODO 临时添加,后面宏宇统一在数据中心处理
|
||||
if (ttsMap.containsKey(v2xType)) {
|
||||
val oldTime = ttsMap[v2xType]
|
||||
val timeDiff = (System.currentTimeMillis() - oldTime!!) / 1000
|
||||
if (timeDiff < 30) {
|
||||
return
|
||||
}
|
||||
ttsMap.remove(v2xType)
|
||||
ttsMap[v2xType] = System.currentTimeMillis()
|
||||
} else {
|
||||
ttsMap[v2xType] = System.currentTimeMillis()
|
||||
}
|
||||
ttsMap.remove(v2xType)
|
||||
ttsMap[v2xType] = System.currentTimeMillis()
|
||||
} else {
|
||||
ttsMap[v2xType] = System.currentTimeMillis()
|
||||
}
|
||||
CallerLogger.d("${SceneConstant.M_OBU}${TAG}", "warningV2X v2xType = $v2xType ---alertContent = $alertContent ---ttsContent = $ttsContent ")
|
||||
val playTTS = !AppIdentityModeUtils.isPassenger(FunctionBuildConfig.appIdentityMode)
|
||||
@@ -124,7 +120,6 @@ class MoGoHmiProvider : IMoGoHmiProvider {
|
||||
CallerLogger.e("$M_HMI$TAG", "Show warningContent is null or empty!")
|
||||
return
|
||||
}
|
||||
|
||||
listener?.onShow()
|
||||
CallerV2XWarningListenerManager.show(v2xType, direction, expireTime)
|
||||
CallerLogger.d(
|
||||
@@ -132,15 +127,13 @@ class MoGoHmiProvider : IMoGoHmiProvider {
|
||||
"--- show v2x dialog 1 ---: info -> v2x-type: $v2xType : expireTime: $expireTime"
|
||||
)
|
||||
lastShowV2XJob?.safeCancel()
|
||||
ProcessLifecycleOwner.get().lifecycleScope.launch(Dispatchers.Main) {
|
||||
ProcessLifecycleOwner.get().lifecycleScope.launch {
|
||||
delay(expireTime)
|
||||
}.also { itx ->
|
||||
lastShowV2XJob = itx
|
||||
}.invokeOnCompletion {
|
||||
listener?.onDismiss()
|
||||
CallerV2XWarningListenerManager.dismiss()
|
||||
}
|
||||
|
||||
Log.d("CODE", "---- 00 ------ tts_content: $ttsContent")
|
||||
if (ttsContent != null && !TextUtils.isEmpty(ttsContent) && playTTS) {
|
||||
val last = lastSpeakJob.get()
|
||||
|
||||
@@ -214,12 +214,7 @@ class CameraListView : FrameLayout {
|
||||
}
|
||||
}
|
||||
}
|
||||
liveStreamManager.setLiveStatusChangeCallback {
|
||||
textureView
|
||||
.post {
|
||||
handleSnLiveStatus(it)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private fun isCarLive(): Boolean {
|
||||
@@ -237,17 +232,6 @@ class CameraListView : FrameLayout {
|
||||
}
|
||||
}
|
||||
|
||||
private fun handleSnLiveStatus(status: Int) {
|
||||
when (status) {
|
||||
0 -> {// 正在直播
|
||||
}
|
||||
1 -> {// 直播已停止
|
||||
}
|
||||
2 -> {// 直播强制结束
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private val trafficCarLiveCallBack = object : ITrafficCarLiveCallBack {
|
||||
override fun onLive(liveSn: String?) {
|
||||
CallerLogger.d("$M_HMI$TAG", "onLive")
|
||||
@@ -291,6 +275,14 @@ class CameraListView : FrameLayout {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onPlaying() {
|
||||
|
||||
}
|
||||
|
||||
override fun onPlaRequesting() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
fun updateCameraData(cameraInfoList: List<CameraEntity>?) {
|
||||
@@ -337,7 +329,6 @@ class CameraListView : FrameLayout {
|
||||
if (valueAnimator.isStarted || valueAnimator.isRunning) {
|
||||
valueAnimator.cancel()
|
||||
}
|
||||
liveStreamManager.setLiveStatusChangeCallback(null)
|
||||
}
|
||||
|
||||
private fun stopLive() {
|
||||
|
||||
@@ -8,13 +8,16 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxCountDownBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgCategory
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.DriverMsgBoxBubbleAdapter
|
||||
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
@@ -30,7 +33,7 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener {
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener,IOrderListener {
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.layout_driver_msg_box_bubble, this, true)
|
||||
@@ -42,6 +45,7 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
|
||||
private val TAG = "DriverMsgBoxBubbleView"
|
||||
private val dataList :ArrayList<MsgBoxCountDownBean> = ArrayList()
|
||||
private var isShowData = true
|
||||
private var isShowSummary = false //是否展示汇总消息
|
||||
|
||||
private fun initView() {
|
||||
val linearLayoutManager = LinearLayoutManager(context)
|
||||
@@ -83,19 +87,27 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
if(isShowData){
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
if(category == MsgCategory.RECORD_BAG){
|
||||
if(!FunctionBuildConfig.isDemoMode){
|
||||
//弹出被动录包弹窗
|
||||
CallerDevaToolsManager.onReceiveBadCaseRecord(msgBoxBean,context as Activity,true)
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
}
|
||||
} else if(category == MsgCategory.SYS_INFO){
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
//todo 过滤MAP系统异常报警
|
||||
} else{
|
||||
clMsgBubbleLayout.visibility = View.VISIBLE
|
||||
val msgBoxCountDownBean = MsgBoxCountDownBean(msgBoxBean)
|
||||
dataList.add(msgBoxCountDownBean)
|
||||
driverMsgBoxBubbleAdapter?.setData(dataList)
|
||||
if(msgBoxBean.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
if(isShowSummary){
|
||||
showData(msgBoxBean)
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
isShowSummary = false
|
||||
}
|
||||
}else{
|
||||
showData(msgBoxBean)
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
}
|
||||
}
|
||||
}
|
||||
}, UiThreadHandler.MODE.QUEUE)
|
||||
@@ -104,11 +116,24 @@ class DriverMsgBoxBubbleView @JvmOverloads constructor(
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
override fun onUpdateOrderStatus(inOrder: Boolean) {
|
||||
isShowSummary = inOrder
|
||||
}
|
||||
|
||||
private fun showData(msgBoxBean: MsgBoxBean){
|
||||
clMsgBubbleLayout.visibility = View.VISIBLE
|
||||
val msgBoxCountDownBean = MsgBoxCountDownBean(msgBoxBean)
|
||||
dataList.add(msgBoxCountDownBean)
|
||||
driverMsgBoxBubbleAdapter?.setData(dataList)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -8,13 +8,16 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgCategory
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxEventListener
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.DriverMsgBoxListAdapter
|
||||
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
@@ -34,7 +37,8 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr) , IMsgBoxListener, IMsgBoxEventListener {
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr) , IMsgBoxListener, IMsgBoxEventListener,
|
||||
IOrderListener {
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.layout_driver_msg_box_list, this, true)
|
||||
@@ -47,6 +51,8 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
private var driverMsgBoxListAdapter: DriverMsgBoxListAdapter ?=null
|
||||
private var linearLayoutManager: LinearLayoutManager ?= null
|
||||
|
||||
private var isShowSummary = false //是否展示汇总消息
|
||||
|
||||
private fun initView() {
|
||||
driverMsgBoxListAdapter= DriverMsgBoxListAdapter(context as Activity)
|
||||
rvMsgBoxList.adapter = driverMsgBoxListAdapter
|
||||
@@ -174,9 +180,20 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
UiThreadHandler.post({
|
||||
when (category) {
|
||||
MsgCategory.NOTICE -> {
|
||||
noticeList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 0){
|
||||
noticeList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
if(msgBoxList.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
if(isShowSummary){
|
||||
noticeList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 0){
|
||||
noticeList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
}
|
||||
isShowSummary = false
|
||||
}
|
||||
}else{
|
||||
noticeList?.add(0,msgBoxList)
|
||||
if(MsgBoxConfig.getUserRecord() == 0){
|
||||
noticeList?.let { driverMsgBoxListAdapter?.setData(it) }
|
||||
}
|
||||
}
|
||||
}
|
||||
MsgCategory.SYS_INFO -> {
|
||||
@@ -199,6 +216,7 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxListenerManager.addListener(TAG,this)
|
||||
CallerMsgBoxEventListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
EventBus.getDefault().register(this)
|
||||
}
|
||||
|
||||
@@ -206,6 +224,7 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxListenerManager.removeListener(TAG)
|
||||
CallerMsgBoxEventListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
EventBus.getDefault().unregister(this)
|
||||
}
|
||||
|
||||
@@ -249,4 +268,8 @@ class DriverMsgBoxListView @JvmOverloads constructor(
|
||||
driverMsgBoxListAdapter?.setReportShowData(msgBoxBean)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onUpdateOrderStatus(inOrder: Boolean) {
|
||||
isShowSummary = inOrder
|
||||
}
|
||||
}
|
||||
@@ -16,6 +16,9 @@ import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import kotlinx.android.synthetic.main.layout_m_msg_box_bubble.view.*
|
||||
|
||||
/**
|
||||
* M1消息盒子气泡态
|
||||
*/
|
||||
class MMsgBoxBubbleView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
|
||||
@@ -7,15 +7,20 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxEventListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import kotlinx.android.synthetic.main.view_m1_msg_box_button.view.*
|
||||
|
||||
/**
|
||||
* M1消息盒子切换按钮
|
||||
*/
|
||||
class MMsgBoxButtonView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
): ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxEventListener {
|
||||
): ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxEventListener, IOrderListener {
|
||||
|
||||
companion object {
|
||||
const val TAG = "MMsgBoxButtonView"
|
||||
@@ -38,11 +43,13 @@ class MMsgBoxButtonView @JvmOverloads constructor(
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxEventListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxEventListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
override fun onSummaryClickEvent() {
|
||||
@@ -81,5 +88,9 @@ class MMsgBoxButtonView @JvmOverloads constructor(
|
||||
fun showMsgBoxList(show: Boolean)
|
||||
}
|
||||
|
||||
override fun onOrderRemoval() {
|
||||
//核销订单,去除红点
|
||||
msgBoxMTipView.visibility = View.GONE
|
||||
}
|
||||
|
||||
}
|
||||
@@ -13,20 +13,26 @@ import com.mogo.eagle.core.data.msgbox.MsgCategory
|
||||
import com.mogo.eagle.core.data.msgbox.OperationMsg
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxEventListener
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.MMsgBoxListAdapter
|
||||
import com.mogo.eagle.core.utilcode.util.ResourceUtils.getDrawable
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import kotlinx.android.synthetic.main.layout_m_msg_box_list.view.*
|
||||
|
||||
/**
|
||||
* M1消息盒子列表
|
||||
*/
|
||||
class MMsgBoxListView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener, IMsgBoxEventListener {
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener, IMsgBoxEventListener,
|
||||
IOrderListener {
|
||||
|
||||
private val TAG = "MMsgBoxListView"
|
||||
var mMsgBoxListAdapter: MMsgBoxListAdapter?= null
|
||||
@@ -73,12 +79,14 @@ class MMsgBoxListView @JvmOverloads constructor(
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxListenerManager.addListener(TAG,this)
|
||||
CallerMsgBoxEventListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxListenerManager.removeListener(TAG)
|
||||
CallerMsgBoxEventListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
override fun onSummaryClickEvent() {
|
||||
@@ -103,4 +111,13 @@ class MMsgBoxListView @JvmOverloads constructor(
|
||||
|
||||
}
|
||||
|
||||
override fun onOrderRemoval() {
|
||||
//清除历史消息,并刷新列表
|
||||
CallerMsgBoxManager.delMsgTable(context)
|
||||
noticeList?.let {
|
||||
it.clear()
|
||||
mMsgBoxListAdapter?.setData(it)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -6,13 +6,16 @@ import android.util.AttributeSet
|
||||
import android.view.*
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxCountDownBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxType
|
||||
import com.mogo.eagle.core.data.msgbox.MsgCategory
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
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
|
||||
@@ -28,12 +31,13 @@ class PassengerMsgBoxBubbleView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener {
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener, IOrderListener {
|
||||
|
||||
private val TAG = "PassengerMsgBoxBubbleView"
|
||||
private val dataList :ArrayList<MsgBoxCountDownBean> = ArrayList()
|
||||
private var passengerMsgBoxBubbleAdapter: PassengerMsgBoxBubbleAdapter ?= null
|
||||
private var isShowData = true
|
||||
private var isShowSummary = false //是否展示汇总消息
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.layout_passenger_msg_box_bubble, this, true)
|
||||
@@ -61,26 +65,44 @@ class PassengerMsgBoxBubbleView @JvmOverloads constructor(
|
||||
if(category == MsgCategory.NOTICE){
|
||||
if(msgBoxList.type == MsgBoxType.NOTICE || msgBoxList.type == MsgBoxType.V2X
|
||||
|| msgBoxList.type == MsgBoxType.OBU){
|
||||
MsgBoxConfig.noticeList.add(msgBoxList)
|
||||
if(isShowData){
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
val msgBoxCountDownBean = MsgBoxCountDownBean(msgBoxList)
|
||||
dataList.add(msgBoxCountDownBean)
|
||||
passengerMsgBoxBubbleAdapter?.setData(dataList)
|
||||
if(msgBoxList.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
if(isShowSummary){
|
||||
operationalData(msgBoxList)
|
||||
isShowSummary = false
|
||||
}
|
||||
}else{
|
||||
operationalData(msgBoxList)
|
||||
}
|
||||
}
|
||||
}
|
||||
},UiThreadHandler.MODE.QUEUE)
|
||||
}
|
||||
|
||||
private fun operationalData(msgBoxList: MsgBoxBean){
|
||||
MsgBoxConfig.noticeList.add(msgBoxList)
|
||||
if(isShowData){
|
||||
CallerMsgBoxEventListenerManager.invokeUpdateTipListener(true)
|
||||
val msgBoxCountDownBean = MsgBoxCountDownBean(msgBoxList)
|
||||
dataList.add(msgBoxCountDownBean)
|
||||
passengerMsgBoxBubbleAdapter?.setData(dataList)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
override fun onUpdateOrderStatus(inOrder: Boolean) {
|
||||
isShowSummary = inOrder
|
||||
}
|
||||
|
||||
}
|
||||
@@ -7,14 +7,17 @@ import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.DividerItemDecoration
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
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.function.api.datacenter.msgbox.IMsgBoxEventListener
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxListener
|
||||
import com.mogo.eagle.core.function.api.order.IOrderListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxListenerManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
|
||||
import com.mogo.eagle.core.function.call.order.CallerOrderListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.msgbox.adapter.PassengerMsgBoxListAdapter
|
||||
import com.mogo.eagle.core.utilcode.util.ResourceUtils.getDrawable
|
||||
@@ -30,11 +33,13 @@ class PassengerMsgBoxListView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener, IMsgBoxEventListener {
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMsgBoxListener, IMsgBoxEventListener,
|
||||
IOrderListener {
|
||||
|
||||
private val TAG = "PassengerMsgBoxListView"
|
||||
var passengerMsgBoxListAdapter: PassengerMsgBoxListAdapter ?= null
|
||||
private var noticeList: ArrayList<MsgBoxBean> ?= null
|
||||
private var isShowSummary = false //是否展示汇总消息
|
||||
|
||||
init{
|
||||
LayoutInflater.from(context).inflate(R.layout.layout_passenger_msg_box_list, this, true)
|
||||
@@ -64,9 +69,20 @@ class PassengerMsgBoxListView @JvmOverloads constructor(
|
||||
if(category == MsgCategory.NOTICE){
|
||||
if(msgBoxList.type == MsgBoxType.NOTICE || msgBoxList.type == MsgBoxType.V2X
|
||||
|| msgBoxList.type == MsgBoxType.OBU){
|
||||
noticeList?.add(0,msgBoxList)
|
||||
noticeList?.let {
|
||||
passengerMsgBoxListAdapter?.setData(it)
|
||||
if(msgBoxList.sourceType == DataSourceType.SUMMARY){
|
||||
//在一次订单中汇总消息只展示一次
|
||||
if(isShowSummary){
|
||||
noticeList?.add(0,msgBoxList)
|
||||
noticeList?.let {
|
||||
passengerMsgBoxListAdapter?.setData(it)
|
||||
}
|
||||
isShowSummary = false
|
||||
}
|
||||
}else{
|
||||
noticeList?.add(0,msgBoxList)
|
||||
noticeList?.let {
|
||||
passengerMsgBoxListAdapter?.setData(it)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -77,12 +93,14 @@ class PassengerMsgBoxListView @JvmOverloads constructor(
|
||||
super.onAttachedToWindow()
|
||||
CallerMsgBoxListenerManager.addListener(TAG,this)
|
||||
CallerMsgBoxEventListenerManager.addListener(TAG,this)
|
||||
CallerOrderListenerManager.addListener(TAG,this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMsgBoxListenerManager.removeListener(TAG)
|
||||
CallerMsgBoxEventListenerManager.removeListener(TAG)
|
||||
CallerOrderListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
override fun onSummaryClickEvent() {
|
||||
@@ -107,4 +125,8 @@ class PassengerMsgBoxListView @JvmOverloads constructor(
|
||||
|
||||
}
|
||||
|
||||
override fun onUpdateOrderStatus(inOrder: Boolean) {
|
||||
isShowSummary = inOrder
|
||||
}
|
||||
|
||||
}
|
||||
@@ -7,6 +7,7 @@ import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.widget.ImageView
|
||||
import android.widget.TextView
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.enums.EventTypeEnumNew
|
||||
@@ -35,6 +36,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
private val operation: Int = 1
|
||||
private val operationReturn: Int = 10
|
||||
private val operationStop: Int = 11
|
||||
private val operationDoorSwitchFail: Int = 13 //车门开启、关闭失败
|
||||
private val notice: Int = 2
|
||||
private val v2x: Int = 3
|
||||
private val report: Int = 4
|
||||
@@ -66,6 +68,11 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
.inflate(R.layout.item_msg_bubble_operation_stop, parent, false)
|
||||
return BubbleOperationStopHolder(view)
|
||||
}
|
||||
operationDoorSwitchFail ->{
|
||||
val view = LayoutInflater.from(parent.context)
|
||||
.inflate(R.layout.item_msg_bubble_operation_door, parent, false)
|
||||
return BubbleOperationDoorFailHolder(view)
|
||||
}
|
||||
report -> {
|
||||
val view = LayoutInflater.from(parent.context).inflate(R.layout.item_msg_bubble_report,parent,false)
|
||||
return BubbleReportHolder(view)
|
||||
@@ -113,6 +120,16 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
val operationStopMsg = it[position].msgBoxBean.bean as OperationMsg
|
||||
holder.tvOperationStopTime.text =
|
||||
TimeUtils.millis2String(operationStopMsg.timestamp, getHourMinFormat())
|
||||
holder.tvOperationStopContent.text = operationStopMsg.content
|
||||
}
|
||||
}
|
||||
//车门开启关闭失败
|
||||
is BubbleOperationDoorFailHolder -> {
|
||||
data?.let{
|
||||
val operationDoorMsg = it[position].msgBoxBean.bean as OperationMsg
|
||||
holder.tvOperationDoorTime.text =
|
||||
TimeUtils.millis2String(operationDoorMsg.timestamp, getHourMinFormat())
|
||||
holder.tvOperationDoorContent.text = operationDoorMsg.content
|
||||
}
|
||||
}
|
||||
is BubbleReportHolder -> {
|
||||
@@ -220,7 +237,10 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
}else if((data!![position].msgBoxBean.bean as OperationMsg).type == 1){
|
||||
//运营平台靠边停车
|
||||
operationStop
|
||||
}else{
|
||||
}else if((data!![position].msgBoxBean.bean as OperationMsg).type == 3){
|
||||
//车门开启关闭失败
|
||||
operationDoorSwitchFail
|
||||
} else{
|
||||
//普通运营平台
|
||||
operation
|
||||
}
|
||||
@@ -259,8 +279,13 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
//运营平台靠边停车通知
|
||||
class BubbleOperationStopHolder(itemView: View): RecyclerView.ViewHolder(itemView){
|
||||
var tvOperationStopTime: TextView = itemView.findViewById(R.id.tvOperationStopTime)
|
||||
var tvOperationStopContent: TextView = itemView.findViewById(R.id.tvOperationStopContent)
|
||||
}
|
||||
//车门开启关闭失败
|
||||
class BubbleOperationDoorFailHolder(itemView: View): RecyclerView.ViewHolder(itemView){
|
||||
var tvOperationDoorTime: TextView = itemView.findViewById(R.id.tvOperationDoorTime)
|
||||
var tvOperationDoorContent: TextView = itemView.findViewById(R.id.tvOperationDoorContent)
|
||||
}
|
||||
|
||||
//Notice
|
||||
class BubbleNoticeHolder(itemView: View): RecyclerView.ViewHolder(itemView){
|
||||
var ivNoticeImage: ImageView = itemView.findViewById(R.id.ivNoticeImage)
|
||||
@@ -275,7 +300,7 @@ class DriverMsgBoxBubbleAdapter(private val activity: Activity) : RecyclerView.A
|
||||
var ivV2XImage: ImageView = itemView.findViewById(R.id.ivV2XImage)
|
||||
var tvV2XTime: TextView = itemView.findViewById(R.id.tvV2XTime)
|
||||
var tvV2XContent: TextView = itemView.findViewById(R.id.tvV2XContent)
|
||||
var clV2XLayout: RoundCanClickConstraintLayout = itemView.findViewById(R.id.clV2XLayout)
|
||||
var clV2XLayout: ConstraintLayout = itemView.findViewById(R.id.clV2XLayout)
|
||||
var tvV2XTitle: TextView = itemView.findViewById(R.id.tvV2XTitle)
|
||||
}
|
||||
|
||||
|
||||
@@ -37,6 +37,7 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
private val operation: Int = 1
|
||||
private val operationReturn: Int = 10
|
||||
private val operationStop: Int = 11
|
||||
private val operationDoorSwitchFail: Int = 13
|
||||
private val notice: Int = 2
|
||||
private val v2x: Int = 3
|
||||
private val report: Int = 5
|
||||
@@ -84,6 +85,11 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
.inflate(R.layout.item_msg_box_operation_stop, parent, false)
|
||||
return MsgBoxOperationStop(view)
|
||||
}
|
||||
operationDoorSwitchFail -> {
|
||||
val view = LayoutInflater.from(parent.context)
|
||||
.inflate(R.layout.item_msg_box_operation_door, parent, false)
|
||||
return MsgBoxOperationDoor(view)
|
||||
}
|
||||
notice -> {
|
||||
val view = LayoutInflater.from(parent.context)
|
||||
.inflate(R.layout.item_msg_box_notice, parent, false)
|
||||
@@ -315,6 +321,16 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
val operationStopMsg = it[position].bean as OperationMsg
|
||||
holder.tvOperationStopTime.text =
|
||||
TimeUtils.millis2String(operationStopMsg.timestamp, getHourMinFormat())
|
||||
holder.tvOperationStopContent.text = operationStopMsg.content
|
||||
}
|
||||
}
|
||||
//运营平台开关门失败
|
||||
is MsgBoxOperationDoor -> {
|
||||
data?.let{
|
||||
val operationDoorMsg = it[position].bean as OperationMsg
|
||||
holder.tvOperationDoorTime.text =
|
||||
TimeUtils.millis2String(operationDoorMsg.timestamp, getHourMinFormat())
|
||||
holder.tvOperationDoorContent.text = operationDoorMsg.content
|
||||
}
|
||||
}
|
||||
is MsgBoxNotice -> {
|
||||
@@ -394,7 +410,10 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
}else if((data!![position].bean as OperationMsg).type == 1){
|
||||
//运营平台靠边停车
|
||||
operationStop
|
||||
}else{
|
||||
}else if((data!![position].bean as OperationMsg).type == 3){
|
||||
//开关门失败
|
||||
operationDoorSwitchFail
|
||||
} else{
|
||||
//普通运营平台
|
||||
operation
|
||||
}
|
||||
@@ -457,8 +476,13 @@ class DriverMsgBoxListAdapter(private val activity: Activity) :
|
||||
//运营平台靠边停车通知
|
||||
class MsgBoxOperationStop(itemView: View) : RecyclerView.ViewHolder(itemView){
|
||||
var tvOperationStopTime: TextView = itemView.findViewById(R.id.tvOperationStopTime)
|
||||
var tvOperationStopContent: TextView = itemView.findViewById(R.id.tvOperationStopContent)
|
||||
}
|
||||
//运营平台开关门失败
|
||||
class MsgBoxOperationDoor(itemView: View) : RecyclerView.ViewHolder(itemView){
|
||||
var tvOperationDoorTime: TextView = itemView.findViewById(R.id.tvOperationDoorTime)
|
||||
var tvOperationDoorContent: TextView = itemView.findViewById(R.id.tvOperationDoorContent)
|
||||
}
|
||||
|
||||
//Notice
|
||||
class MsgBoxNotice(itemView: View) : RecyclerView.ViewHolder(itemView) {
|
||||
var ivNoticeImage: ImageView = itemView.findViewById(R.id.ivNoticeImage)
|
||||
|
||||
@@ -10,7 +10,6 @@ import android.os.Build
|
||||
import android.os.Process
|
||||
import android.text.Html
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.annotation.RequiresApi
|
||||
@@ -45,6 +44,7 @@ import com.mogo.eagle.core.data.map.MogoLocation
|
||||
import com.mogo.eagle.core.data.obu.MogoObuConst
|
||||
import com.mogo.eagle.core.data.obu.ObuStatusInfo
|
||||
import com.mogo.eagle.core.data.deva.report.ReportEntity
|
||||
import com.mogo.eagle.core.data.multidisplay.TelematicConstant
|
||||
import com.mogo.eagle.core.function.api.autopilot.*
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsFuncConfigListener
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsListener
|
||||
@@ -67,7 +67,6 @@ import com.mogo.eagle.core.function.hmi.ui.logcatch.LogInfoView
|
||||
import com.mogo.eagle.core.function.hmi.ui.widget.DemoModeView
|
||||
import com.mogo.eagle.core.utilcode.kotlin.*
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.LogLevel
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.Logger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
@@ -75,6 +74,7 @@ import com.mogo.eagle.core.utilcode.mogo.permissions.BackgrounderPermission
|
||||
import com.mogo.eagle.core.utilcode.mogo.storage.SharedPrefsMgr
|
||||
import com.mogo.eagle.core.utilcode.mogo.toast.TipToast
|
||||
import com.mogo.eagle.core.utilcode.util.*
|
||||
import com.mogo.map.hdcache.IHdCacheListener
|
||||
import com.mogo.map.uicontroller.VisualAngleMode
|
||||
import com.mogo.map.uicontroller.VisualAngleMode.*
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.*
|
||||
@@ -157,7 +157,6 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
|
||||
//OBU连接状态
|
||||
private var obuConnectStatus: Boolean = false
|
||||
private var mObuInfoStr: String = ""
|
||||
|
||||
//渠道包标签
|
||||
private var onlineSelected: Boolean = true
|
||||
@@ -180,6 +179,9 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
|
||||
private var isStarted = false
|
||||
|
||||
// 高精地图是否已缓存
|
||||
private var isHDCached = false
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.view_debug_setting, this, true)
|
||||
initView()
|
||||
@@ -325,6 +327,9 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 蘑方点击事件
|
||||
*/
|
||||
tbMojie.setOnCheckedChangeListener { buttonView, isChecked ->
|
||||
if (isChecked) {
|
||||
buttonView.setCompoundDrawables(null, null, iconDown, null)
|
||||
@@ -335,6 +340,21 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* APP升级点击事件
|
||||
*/
|
||||
tbAppUpgrade.setOnCheckedChangeListener { buttonView, isChecked ->
|
||||
if (isChecked) {
|
||||
buttonView.setCompoundDrawables(null, null, iconDown, null)
|
||||
tvAppHost.visibility = View.VISIBLE
|
||||
tvAppContent.visibility = View.VISIBLE
|
||||
} else {
|
||||
buttonView.setCompoundDrawables(null, null, iconRight, null)
|
||||
tvAppHost.visibility = View.GONE
|
||||
tvAppContent.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 蘑方控制 默认关闭
|
||||
*/
|
||||
@@ -553,6 +573,32 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
btn_cache_hd_map?.onClick {
|
||||
if (isHDCached) {
|
||||
ToastUtils.showShort(resources.getString(R.string.offline_had_downloaded))
|
||||
} else {
|
||||
if (CallerMapUIServiceManager.getCityCode().isNullOrEmpty()) {// 未拿到高德的cityCode
|
||||
if (mGnssInfo == null || (mGnssInfo!!.longitude <= 0.0 && mGnssInfo!!.latitude <= 0.0)) {// 未拿到高精的经纬度
|
||||
ToastUtils.showShort(resources.getString(R.string.location_try_again))
|
||||
} else {// 拿到了高精的经纬度
|
||||
cacheHDOfflineData(false)
|
||||
}
|
||||
} else {// 拿到高德的cityCode
|
||||
cacheHDOfflineData(true)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (AppIdentityModeUtils.isPassenger(FunctionBuildConfig.appIdentityMode)) {
|
||||
ThreadUtils.getIoPool().execute {
|
||||
val isCached = CallerMapUIServiceManager.isCityDataCached()
|
||||
isHDCached = isCached
|
||||
UiThreadHandler.post {
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(${if (isCached) "已是最新版" else "待更新"}!)"
|
||||
}
|
||||
}
|
||||
btn_cache_hd_map.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改自车按钮(出租车、小巴车)
|
||||
@@ -563,7 +609,7 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
CallerMapUIServiceManager.getMapUIController()?.changeCurrentIcon(R.raw.chuzuche)
|
||||
} else {
|
||||
// 替换为小巴车图标
|
||||
CallerMapUIServiceManager.getMapUIController()?.changeCurrentIcon(R.raw.xiaobache)
|
||||
CallerMapUIServiceManager.getMapUIController()?.changeCurrentIcon(R.raw.xiaoba)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -579,6 +625,17 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 控制乘客屏直播监控
|
||||
*/
|
||||
tbControlPassengerDriverMonitor.setOnCheckedChangeListener { _, isChecked ->
|
||||
if (isChecked) {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.CONTROL_PASSENGER_DRIVER_MONITOR, "1".toByteArray())
|
||||
} else {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.CONTROL_PASSENGER_DRIVER_MONITOR, "0".toByteArray())
|
||||
}
|
||||
}
|
||||
|
||||
//设置鹰眼本地参数配置监听
|
||||
setEagleEyeConfigListener()
|
||||
//域控制器中心事件点击监听
|
||||
@@ -615,6 +672,16 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
//obu设置50ms的频率发送数据
|
||||
btnSetFifty.setOnClickListener {
|
||||
CallerObuApiManager.setHvInfoSendCycle(50)
|
||||
}
|
||||
|
||||
//obu设置100ms的频率发送数据
|
||||
btnSetOneHundred.setOnClickListener {
|
||||
CallerObuApiManager.setHvInfoSendCycle(100)
|
||||
}
|
||||
|
||||
btnDrawFusion.isChecked = FunctionBuildConfig.isFusionColor
|
||||
btnDrawFusion.setOnCheckedChangeListener { _, isChecked ->
|
||||
FunctionBuildConfig.isFusionColor = isChecked
|
||||
@@ -677,18 +744,6 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
FunctionBuildConfig.isBeautyMode = isChecked
|
||||
}
|
||||
|
||||
tbDrawAiCloudFusion.isChecked = FunctionBuildConfig.isDrawAiCloudFusion
|
||||
//云端感知绘制
|
||||
tbDrawAiCloudFusion.setOnCheckedChangeListener { _, isChecked ->
|
||||
FunctionBuildConfig.isDrawAiCloudFusion = isChecked
|
||||
}
|
||||
|
||||
tbDrawRomaMode.isChecked = FunctionBuildConfig.isRomaMode
|
||||
//roma
|
||||
tbDrawRomaMode.setOnCheckedChangeListener { _, isChecked ->
|
||||
FunctionBuildConfig.isRomaMode = isChecked
|
||||
}
|
||||
|
||||
tbObuWarningFusionUnion.isChecked = FunctionBuildConfig.isObuWarningFusionUnion
|
||||
//ObuWarningFusionUnion
|
||||
tbObuWarningFusionUnion.setOnCheckedChangeListener { _, isChecked ->
|
||||
@@ -983,6 +1038,19 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
tbReportWarning.visibility = GONE
|
||||
}
|
||||
|
||||
|
||||
//是否开启无轨迹发送自驾命令
|
||||
tbStartAutopilotCommand.isChecked = FunctionBuildConfig.isPassStartAutopilotCommand
|
||||
tbStartAutopilotCommand.setOnCheckedChangeListener { _, isChecked ->
|
||||
FunctionBuildConfig.isPassStartAutopilotCommand = isChecked
|
||||
}
|
||||
|
||||
if (!AppIdentityModeUtils.isTaxiDriver(FunctionBuildConfig.appIdentityMode)
|
||||
&& !AppIdentityModeUtils.isBusDriver(FunctionBuildConfig.appIdentityMode)){
|
||||
tbStartAutopilotCommand.visibility = GONE
|
||||
}
|
||||
|
||||
|
||||
//切换环境
|
||||
tvCurEnv.text = "当前环境:${CallerDevaToolsManager.getEnvCityName()}${CallerDevaToolsManager.getEnvNetMode()}"
|
||||
btChangeEnv.onClick {
|
||||
@@ -1509,8 +1577,8 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
/**
|
||||
* 版本信息
|
||||
*/
|
||||
tvAppVersionName.text = "鹰眼版本名:${AppUtils.getAppVersionName()}"
|
||||
tvAppVersionNameKey.text = "鹰眼版本名:${AppUtils.getAppVersionName()}"
|
||||
tvAppVersionName.text = "鹰眼版本:${AppUtils.getAppVersionName()} Git Hash:${AppConfigInfo.workingBranchHash}"
|
||||
tvAppVersionNameKey.text = "鹰眼版本:${AppUtils.getAppVersionName()} Git Hash:${AppConfigInfo.workingBranchHash}"
|
||||
|
||||
tvAutopilotProtocolVersionInfo.text =
|
||||
"Autopilot协议版本:${CallerAutoPilotControlManager.getProtocolVersion()}"
|
||||
@@ -1637,6 +1705,10 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
tvCmdbCarInfoContent.text = SharedPrefsMgr.getInstance(context).getString(SharedPrefsConstants.CAR_INFO)?:""
|
||||
|
||||
//APP升级功能
|
||||
tvAppHost.text = "HOST地址:" + SharedPrefsMgr.getInstance(context).getString(SharedPrefsConstants.HOST_ADDRESS)?:""
|
||||
tvAppContent.text = "APP升级数据:" + SharedPrefsMgr.getInstance(context).getString(SharedPrefsConstants.APP_UPGRADE_CONTENT)?:""
|
||||
|
||||
tvCarInfo.text =
|
||||
"GPS时间:${(mGnssInfo?.satelliteTime?.times(1000))?.toLong()}\n" +
|
||||
"自车经纬度:\n${mGnssInfo?.longitude}\n${mGnssInfo?.latitude}\n"
|
||||
@@ -1672,8 +1744,6 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
} else {
|
||||
tbIsDemoMode?.text = "开启美化模式"
|
||||
}
|
||||
//obu信息,排查obu相关问题使用
|
||||
tvObuInfoContent.text = mObuInfoStr
|
||||
|
||||
obuConnectStatusTv.text = Html.fromHtml(
|
||||
"OBU连接状态:${
|
||||
@@ -2081,6 +2151,52 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
Process.killProcess(Process.myPid())
|
||||
}
|
||||
|
||||
private fun cacheHDOfflineData(isGaoDe: Boolean) {
|
||||
var progss = 0
|
||||
if (isGaoDe) {// 拿到了高德地图的cityCode
|
||||
CallerMapUIServiceManager.cacheHDDataByCity(object : IHdCacheListener {
|
||||
override fun onMapHdCacheProgress(cityId: Int, progress: Double) {
|
||||
// 更新进度
|
||||
progss = progress.toInt()
|
||||
if (progss == 100) {
|
||||
isHDCached = true
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(已是最新版!)"
|
||||
} else {
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(进度:${progss}%)"
|
||||
}
|
||||
}
|
||||
|
||||
override fun onMapHdCacheResult(cityId: Int, state: Int) {
|
||||
if (state == 0) {// 失败
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(下载失败!)"
|
||||
ToastUtils.showShort("下载失败,请重试!")
|
||||
}
|
||||
}
|
||||
})
|
||||
} else {// 只拿到了高精的经纬度
|
||||
mGnssInfo?.let { loc ->
|
||||
CallerMapUIServiceManager.cacheHDDataByCityByLonLat(object : IHdCacheListener {
|
||||
override fun onMapHdCacheProgress(cityId: Int, progress: Double) {
|
||||
progss = progress.toInt()
|
||||
if (progss == 100) {
|
||||
isHDCached = true
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(已是最新版!)"
|
||||
} else {
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(进度:${progss}%)"
|
||||
}
|
||||
}
|
||||
|
||||
override fun onMapHdCacheResult(cityId: Int, state: Int) {
|
||||
if (state == 0) {// 失败
|
||||
btn_cache_hd_map.text = "缓存高精离线地图(下载失败!)"
|
||||
ToastUtils.showShort("下载失败,请重试!")
|
||||
}
|
||||
}
|
||||
}, loc)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun fwThreadClose() {
|
||||
refreshTraceInfo()
|
||||
}
|
||||
@@ -2090,7 +2206,12 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
setLogCheckedChangeListener()
|
||||
}
|
||||
|
||||
override fun onGetObuInfo(obuInfoStr: String) {
|
||||
mObuInfoStr = obuInfoStr
|
||||
override fun onGetObuInfo(obuInfoStr: String?) {
|
||||
obuInfoStr?.let {
|
||||
//obu信息,排查obu相关问题使用
|
||||
UiThreadHandler.post {
|
||||
tvObuInfoContent.text = it
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2,13 +2,13 @@ package com.mogo.eagle.core.function.hmi.ui.setting
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.config.HmiBuildConfig
|
||||
import com.mogo.eagle.core.data.deva.bizconfig.FuncBizConfig
|
||||
import com.mogo.eagle.core.data.multidisplay.TelematicConstant
|
||||
import com.mogo.eagle.core.data.obu.MogoObuConst
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsFuncConfigListener
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IViewControlListener
|
||||
@@ -21,6 +21,7 @@ import com.mogo.eagle.core.utilcode.kotlin.currentPadding
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiViewControlListenerManager
|
||||
import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager
|
||||
import com.mogo.eagle.core.function.call.v2x.CallerTrafficLightListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.ui.widget.DemoModeView
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
@@ -87,6 +88,18 @@ internal class SOPSettingView @JvmOverloads constructor(
|
||||
HmiBuildConfig.isShowCloudWeaknessTrafficView = isChecked
|
||||
}
|
||||
|
||||
/**
|
||||
* V2N场景进PNC
|
||||
*/
|
||||
tbV2nPnc.isChecked = FunctionBuildConfig.isV2NPnc
|
||||
tbV2nPnc.setOnCheckedChangeListener{ compoundButton, isChecked ->
|
||||
if(!compoundButton.isPressed){
|
||||
return@setOnCheckedChangeListener
|
||||
}
|
||||
CallerAutoPilotControlManager.sendV2nToPncCmd(isChecked)
|
||||
FunctionBuildConfig.isV2NPnc = isChecked
|
||||
}
|
||||
|
||||
/**
|
||||
* obu V2V开关,默认打开
|
||||
*/
|
||||
@@ -103,6 +116,32 @@ internal class SOPSettingView @JvmOverloads constructor(
|
||||
HmiBuildConfig.isShowObuV2iView = isChecked
|
||||
}
|
||||
|
||||
/**
|
||||
* obu 闯红灯预警,默认关闭
|
||||
*/
|
||||
tbRunRedLightSop.isChecked = HmiBuildConfig.isShowRunRedLightView
|
||||
tbRunRedLightSop.setOnCheckedChangeListener { _, isChecked ->
|
||||
HmiBuildConfig.isShowRunRedLightView = isChecked
|
||||
if (HmiBuildConfig.isShowRunRedLightView) {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.OBU_RUNREDLIGHT_WARNING, "1".toByteArray())
|
||||
} else {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.OBU_RUNREDLIGHT_WARNING, "0".toByteArray())
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* obu 绿波通行,默认关闭
|
||||
*/
|
||||
tbGreenWaveSop.isChecked = HmiBuildConfig.isShowGreenWaveView
|
||||
tbGreenWaveSop.setOnCheckedChangeListener { _, isChecked ->
|
||||
HmiBuildConfig.isShowGreenWaveView = isChecked
|
||||
if (HmiBuildConfig.isShowGreenWaveView) {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.OBU_GREENWAVE_WARNING, "1".toByteArray())
|
||||
} else {
|
||||
CallerTelematicManager.sendMsgToAllClients(TelematicConstant.OBU_GREENWAVE_WARNING, "0".toByteArray())
|
||||
}
|
||||
}
|
||||
|
||||
//红绿灯标识
|
||||
tbTrafficLight.isChecked = HmiBuildConfig.isShowTrafficLightView
|
||||
tbTrafficLight.setOnCheckedChangeListener { _, isChecked ->
|
||||
@@ -179,6 +218,11 @@ internal class SOPSettingView @JvmOverloads constructor(
|
||||
FunctionBuildConfig.isReportWarning = isChecked
|
||||
}
|
||||
|
||||
tbNewV2NData.isChecked = FunctionBuildConfig.isNewV2NData
|
||||
tbNewV2NData.setOnCheckedChangeListener { _, isChecked ->
|
||||
FunctionBuildConfig.isNewV2NData = isChecked
|
||||
}
|
||||
|
||||
//变道绕障的目标障碍物速度阈值
|
||||
tvSpeed.text = "${FunctionBuildConfig.detouringSpeed} m/s"
|
||||
ivSpeedReduce.setOnClickListener {
|
||||
|
||||
@@ -28,6 +28,10 @@ class ToggleDebugView private constructor() : IMoGoAutopilotStatusListener {
|
||||
private var mDebugSettingViewFloat: WarningFloat.Builder? = null
|
||||
private var mDebugSettingView: DebugSettingView? = null
|
||||
|
||||
fun isShowIng():Boolean{
|
||||
return mDebugSettingViewFloat != null
|
||||
}
|
||||
|
||||
/**
|
||||
* 开关DebugView
|
||||
*/
|
||||
@@ -85,7 +89,7 @@ class ToggleDebugView private constructor() : IMoGoAutopilotStatusListener {
|
||||
}
|
||||
}
|
||||
|
||||
private fun dismiss() {
|
||||
fun dismiss() {
|
||||
mDebugSettingViewFloat?.let {
|
||||
WarningFloat.dismiss(it.config.floatTag, false)
|
||||
mDebugSettingViewFloat = null
|
||||
|
||||
@@ -19,6 +19,7 @@ import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotCarConfigListenerManager
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.utils.KeyBoardUtil
|
||||
import com.mogo.eagle.core.function.msgbox.MsgBoxConfig
|
||||
@@ -136,11 +137,10 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
//录包管理页面
|
||||
clickListener?.showBadCaseManagerView()
|
||||
}
|
||||
//BadCase上报
|
||||
CallerDevaToolsManager.initAiCollect(badCaseLayout)
|
||||
ivDebugPanel.setOnClickListener {
|
||||
clickListener?.showDebugPanelView()
|
||||
|
||||
|
||||
|
||||
}
|
||||
ivDebugFeedback.onClick {
|
||||
clickListener?.showFeedbackView()
|
||||
@@ -182,6 +182,7 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
return@setOnTouchListener false
|
||||
}
|
||||
}
|
||||
|
||||
ivSpeedReduce.setOnClickListener {
|
||||
if(speedLimit>=5){
|
||||
speedLimit -= 5
|
||||
|
||||
@@ -47,7 +47,8 @@ class BusOperationView @JvmOverloads constructor(
|
||||
ivGotoPersonalInfo.visibility = GONE
|
||||
}
|
||||
|
||||
if (AppIdentityModeUtils.isShuttle(FunctionBuildConfig.appIdentityMode)) {
|
||||
if (AppIdentityModeUtils.isShuttle(FunctionBuildConfig.appIdentityMode) ||
|
||||
AppIdentityModeUtils.isCharter(FunctionBuildConfig.appIdentityMode)) {
|
||||
actvAccountQR.visibility = VISIBLE
|
||||
}else{
|
||||
actvAccountQR.visibility = GONE
|
||||
|
||||
@@ -4,10 +4,16 @@ import android.content.Context
|
||||
import android.view.View
|
||||
import android.widget.TextView
|
||||
import androidx.lifecycle.LifecycleObserver
|
||||
import com.mogo.eagle.core.function.api.devatools.download.DownloadType.APK
|
||||
import com.mogo.eagle.core.function.api.devatools.download.DownloadType.PATCH
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager
|
||||
import com.mogo.eagle.core.function.call.patch.*
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.eagle.core.function.hmi.dialog.BaseFloatDialog
|
||||
import com.mogo.eagle.core.utilcode.kotlin.*
|
||||
import kotlinx.coroutines.*
|
||||
import java.lang.ref.WeakReference
|
||||
|
||||
/**
|
||||
* @brief APP升级提示弹框
|
||||
@@ -18,7 +24,7 @@ class UpgradeAppDialog(context: Context) : BaseFloatDialog(context), LifecycleOb
|
||||
companion object{
|
||||
private const val TAG = "UpgradeAppDialog"
|
||||
|
||||
private var upgradeAppDialog: UpgradeAppDialog? = null
|
||||
private var upgradeAppDialog: WeakReference<UpgradeAppDialog>? = null
|
||||
|
||||
fun show(context: Context?,
|
||||
name: String,
|
||||
@@ -27,10 +33,12 @@ class UpgradeAppDialog(context: Context) : BaseFloatDialog(context), LifecycleOb
|
||||
content: String,
|
||||
installType: String) {
|
||||
context?.let {
|
||||
if (upgradeAppDialog == null) {
|
||||
upgradeAppDialog = UpgradeAppDialog(it)
|
||||
var dialog = upgradeAppDialog?.get()
|
||||
if (dialog == null) {
|
||||
dialog = UpgradeAppDialog(it)
|
||||
upgradeAppDialog = WeakReference(dialog)
|
||||
}
|
||||
upgradeAppDialog?.let { dialog ->
|
||||
dialog.let { d ->
|
||||
if (dialog.isShowing) {
|
||||
return
|
||||
}
|
||||
@@ -78,10 +86,19 @@ class UpgradeAppDialog(context: Context) : BaseFloatDialog(context), LifecycleOb
|
||||
/**
|
||||
* 去下载
|
||||
*/
|
||||
fun downloadApp() {
|
||||
private fun downloadApp() {
|
||||
ToastUtils.showLong("开始下载APK,稍后可前往downloads文件夹查看,通知栏查看下载进度")
|
||||
tag?.let { downloadUrl?.let { it1 -> CallerDevaToolsManager.downLoadPackage(it, it1) } }
|
||||
|
||||
tag?.let {
|
||||
downloadUrl?.let { url ->
|
||||
window?.decorView?.scope?.launch {
|
||||
if (CallerPatchManager.getPatchInfoByUrl(url) != null) {
|
||||
CallerDevaToolsManager.downLoadPackage(PATCH, it, url)
|
||||
} else {
|
||||
CallerDevaToolsManager.downLoadPackage(APK, it, url)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
dismiss()
|
||||
}
|
||||
|
||||
|
||||
@@ -60,7 +60,6 @@ class TakeOverView @JvmOverloads constructor(
|
||||
}else if(autoPilotStatusInfo.state == 0 || autoPilotStatusInfo.state == 1){
|
||||
isParallel = false
|
||||
}
|
||||
Log.i(TAG,"自动驾驶状态${autopilotStatus}")
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -80,39 +79,44 @@ class TakeOverView @JvmOverloads constructor(
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_PLANNING,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_LOCATION,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_CHASSIS,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_DISTANCE ->{
|
||||
CallerHmiManager.warningV2X(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.tts,
|
||||
object : IMoGoWarningStatusListener {
|
||||
override fun onShow() {
|
||||
takeOver = true
|
||||
visibility = View.VISIBLE
|
||||
//加入消息盒子
|
||||
saveMsgBox(
|
||||
MsgBoxBean(
|
||||
MsgBoxType.V2X, V2XMsg(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.tts
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_DISTANCE -> {
|
||||
if(!isParallel){
|
||||
CallerHmiManager.warningV2X(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.tts,
|
||||
object : IMoGoWarningStatusListener {
|
||||
override fun onShow() {
|
||||
takeOver = true
|
||||
ThreadUtils.runOnUiThread{
|
||||
visibility = View.VISIBLE
|
||||
}
|
||||
//加入消息盒子
|
||||
saveMsgBox(
|
||||
MsgBoxBean(
|
||||
MsgBoxType.V2X, V2XMsg(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.tts
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
takeOver = false
|
||||
visibility = View.GONE
|
||||
}
|
||||
}
|
||||
)
|
||||
override fun onDismiss() {
|
||||
takeOver = false
|
||||
ThreadUtils.runOnUiThread{
|
||||
visibility = View.GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
,isFromObu = false)
|
||||
}
|
||||
}
|
||||
//弱网
|
||||
MogoReport.Code.Error.EMAP.EPARALLEL_AICLOUD_NETWORK_WEAK,
|
||||
MogoReport.Code.Error.EMAP.EPARALLEL_AICLOUD_CONNECTION_ERROR -> {
|
||||
MogoReport.Code.Error.EPARALLEL.AICLOUD_NETWORK_WEAK,
|
||||
MogoReport.Code.Error.EPARALLEL.AICLOUD_CONNECTION_ERROR -> {
|
||||
//如果是平行驾驶状态下,提示弱网接管
|
||||
Log.i(TAG,"弱网时自动驾驶状态:${autopilotStatus}")
|
||||
if(isParallel){
|
||||
CallerHmiManager.warningV2X(
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.poiType,
|
||||
@@ -121,9 +125,10 @@ class TakeOverView @JvmOverloads constructor(
|
||||
object : IMoGoWarningStatusListener {
|
||||
override fun onShow() {
|
||||
takeOver = true
|
||||
visibility = View.VISIBLE
|
||||
ThreadUtils.runOnUiThread{
|
||||
visibility = View.VISIBLE
|
||||
}
|
||||
//加入消息盒子
|
||||
Log.i(TAG,"弱网时加入消息盒子${EventTypeEnumNew.NETWORK_WEAK_EVENT.content}")
|
||||
saveMsgBox(
|
||||
MsgBoxBean(
|
||||
MsgBoxType.V2X, V2XMsg(
|
||||
@@ -137,10 +142,12 @@ class TakeOverView @JvmOverloads constructor(
|
||||
|
||||
override fun onDismiss() {
|
||||
takeOver = false
|
||||
visibility = View.GONE
|
||||
ThreadUtils.runOnUiThread{
|
||||
visibility = View.GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
)
|
||||
,isFromObu = false)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,237 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.app.Application
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import com.mogo.cloud.live.manager.LiveStreamManagerImpl
|
||||
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
|
||||
import com.mogo.cloud.trafficlive.api.ITrafficCarLiveCallBack
|
||||
import com.mogo.cloud.trafficlive.api.MoGoAiCloudTrafficLive
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.Logger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.eagle.core.widget.RoundConstraintLayout
|
||||
import kotlinx.android.synthetic.main.view_driver_monitor.view.ivNormal
|
||||
import kotlinx.android.synthetic.main.view_driver_monitor.view.liveProgressBar
|
||||
import kotlinx.android.synthetic.main.view_driver_monitor.view.textureViewDriverMonitor
|
||||
import kotlinx.android.synthetic.main.view_driver_monitor.view.tvLoadingHit
|
||||
|
||||
/**
|
||||
* 乘客端查看当前车辆驾驶舱的司机监控View
|
||||
*/
|
||||
class DriverMonitorView :
|
||||
RoundConstraintLayout {
|
||||
companion object {
|
||||
private val TAG = "DriverMonitorView"
|
||||
}
|
||||
|
||||
// TODO SOP演示功能代码,乘客端查看当前车辆上的司机位置监控,请求的是分体机提供的直播信息,这里采用的是硬编码,因为云平台的操作就是这样,没有接口供查询对应关系
|
||||
private var sopShowDriverMap = HashMap<String, String>()
|
||||
private var isLived = false
|
||||
|
||||
// 调用直播传入的司机屏幕SN
|
||||
private var currentDriverSN = ""
|
||||
|
||||
// 当前直播源的SN,TODO 如果要测试可以使用下面的SN
|
||||
// private var currentDriverLiveSN = "F803EB2046PZD00164"
|
||||
private var currentDriverLiveSN = ""
|
||||
|
||||
|
||||
var liveListener: LiveListener? = null
|
||||
|
||||
constructor(context: Context?) : super(context) {
|
||||
initView(context)
|
||||
}
|
||||
|
||||
constructor(context: Context?, attrs: AttributeSet?) : super(context, attrs) {
|
||||
initView(context)
|
||||
}
|
||||
|
||||
constructor(context: Context?, attrs: AttributeSet?, defStyleAttr: Int) : super(
|
||||
context,
|
||||
attrs,
|
||||
defStyleAttr
|
||||
) {
|
||||
initView(context)
|
||||
}
|
||||
|
||||
private fun initView(context: Context?) {
|
||||
LayoutInflater.from(context)
|
||||
.inflate(R.layout.view_driver_monitor, this, true)
|
||||
|
||||
textureViewDriverMonitor.isOpaque = false
|
||||
|
||||
// TODO SOP演示需求,只有乘客屏幕才会触发这个逻辑 ,车上必须配置了分体机作为直播源 begin
|
||||
// http://wiki.zhidaohulian.com/pages/viewpage.action?pageId=111386656
|
||||
// 测试数据
|
||||
sopShowDriverMap["F803EB2046PZD00164"] = "F803EB2046PZD00164"//凤坤工位旁的分体机
|
||||
sopShowDriverMap["X20202105189C2522114198E7B3"] = "F803EB2046PZD00164"//凤坤工位旁的分体机
|
||||
sopShowDriverMap["X202022060289M7N8P"] = "F803EB2046PZD00188"//湘A01733D
|
||||
// key=pad司机屏幕SN,value=分体机SN,value用来调用ZeGo直播服务查看直播,@see MoGoAiCloudTrafficLive.viewDesignativeVehicleLive
|
||||
sopShowDriverMap["20220524733SWT1"] = "F803EB2046PZD00190"//湘D01777D
|
||||
sopShowDriverMap["20211110K7EJKPG"] = "F803EB2046PZD00188"//湘A01733D
|
||||
sopShowDriverMap["20211120H342O9Z"] = "F803EB2046PZD00167"//未知
|
||||
sopShowDriverMap["20211112X2RI32A"] = "F803EB2046PZD00274"//京A40776D
|
||||
sopShowDriverMap["202204085X310A1"] = "F803EB2046PZD00263"//湘D09005D
|
||||
|
||||
// TODO SOP演示需求,只有乘客屏幕才会触发这个逻辑 END
|
||||
// 点击重新连接直播
|
||||
ivNormal.setOnClickListener {
|
||||
startLive()
|
||||
}
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
if (currentDriverLiveSN.isNotEmpty()) {
|
||||
MoGoAiCloudTrafficLive.stopCarLive(currentDriverLiveSN)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 检查传入的司机端所在车辆是否配置了,F车机作为直播源。ture-有,false-没有
|
||||
*/
|
||||
fun isSOPDriverSn(snDriver: String): Boolean {
|
||||
currentDriverSN = snDriver
|
||||
// 查找传入的司机端所在车是否配置了F车机作为直播源
|
||||
sopShowDriverMap[snDriver]?.let {
|
||||
// 这里应对的是乘客端切换连接的司机端的情况,正常情况这里不会执行,一个车只有一个司机端
|
||||
if (isLived && it != currentDriverLiveSN) {
|
||||
stopLive()
|
||||
}
|
||||
currentDriverLiveSN = it
|
||||
|
||||
// 这里知只是了初始化下直播SDK,防止直接调用观看直播时候还未登录问题
|
||||
LiveStreamManagerImpl.getInstance(
|
||||
context.applicationContext as Application?,
|
||||
MoGoAiCloudClientConfig.getInstance().sn,
|
||||
false
|
||||
)
|
||||
} ?: let {
|
||||
// 如果没查到,设置当前车辆为null,并将之前的直播关闭
|
||||
stopLive()
|
||||
currentDriverLiveSN = ""
|
||||
}
|
||||
|
||||
Logger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"当前车上的司机端SN=${currentDriverSN},直播分体机SN=${currentDriverLiveSN}"
|
||||
)
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"当前车上的司机端SN=${currentDriverSN},直播分体机SN=${currentDriverLiveSN}"
|
||||
)
|
||||
return currentDriverLiveSN.isNotEmpty()
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 打开,司机仓监控直播
|
||||
*/
|
||||
fun startLive() {
|
||||
if (currentDriverLiveSN.isNotEmpty()) {
|
||||
Logger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"检查司机直播……isLived=$isLived 当前车上的司机端SN=${currentDriverSN},直播分体机SN=${currentDriverLiveSN}"
|
||||
)
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"检查司机直播……isLived=$isLived 当前车上的司机端SN=${currentDriverSN},直播分体机SN=${currentDriverLiveSN}"
|
||||
)
|
||||
if (!isLived) {
|
||||
MoGoAiCloudTrafficLive.viewDesignativeVehicleLive(
|
||||
currentDriverLiveSN,
|
||||
textureViewDriverMonitor,
|
||||
carLiveCallBack
|
||||
)
|
||||
} else {
|
||||
ToastUtils.showShort("正在直播中")
|
||||
}
|
||||
} else {
|
||||
ToastUtils.showShort("当前车内没有直播源")
|
||||
//为空又怎么撸
|
||||
Logger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"检查司机直播……isLived=$isLived 当前车辆SN=${currentDriverSN} 不支持直播"
|
||||
)
|
||||
CallerLogger.d(
|
||||
"${SceneConstant.M_HMI}$TAG",
|
||||
"检查司机直播……isLived=$isLived 当前车辆SN=${currentDriverSN} 不支持直播"
|
||||
)
|
||||
// 乘客屏幕连接上了司机屏,但是司机屏不在直播范围内,进行隐藏操作。
|
||||
liveListener?.onPlayError()
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 关闭,司机仓监控直播
|
||||
*/
|
||||
fun stopLive() {
|
||||
isLived = false
|
||||
if (currentDriverLiveSN.isNotEmpty()) {
|
||||
MoGoAiCloudTrafficLive.stopCarLive(currentDriverLiveSN)
|
||||
}
|
||||
}
|
||||
|
||||
private fun refreshView(lived: Boolean) {
|
||||
if (lived) {
|
||||
textureViewDriverMonitor.visibility = VISIBLE
|
||||
liveProgressBar.visibility = GONE
|
||||
tvLoadingHit.visibility = GONE
|
||||
} else {
|
||||
textureViewDriverMonitor.visibility = GONE
|
||||
liveProgressBar.visibility = VISIBLE
|
||||
tvLoadingHit.visibility = VISIBLE
|
||||
}
|
||||
}
|
||||
|
||||
private val carLiveCallBack = object : ITrafficCarLiveCallBack {
|
||||
override fun onLive(liveSn: String?) {
|
||||
Logger.i("${SceneConstant.M_HMI}$TAG", "onLive:$liveSn")
|
||||
CallerLogger.d("${SceneConstant.M_HMI}$TAG", "onLive:$liveSn")
|
||||
}
|
||||
|
||||
override fun onFirstFrame() {
|
||||
Logger.i("${SceneConstant.M_HMI}$TAG", "onFirstFrame:isFirstPage")
|
||||
CallerLogger.d("${SceneConstant.M_HMI}$TAG", "onFirstFrame:isFirstPage")
|
||||
isLived = true
|
||||
refreshView(isLived)
|
||||
}
|
||||
|
||||
override fun onDisConnect() {
|
||||
Logger.w("${SceneConstant.M_HMI}$TAG", "onDisConnect")
|
||||
CallerLogger.w("${SceneConstant.M_HMI}$TAG", "onDisConnect")
|
||||
isLived = false
|
||||
refreshView(isLived)
|
||||
}
|
||||
|
||||
override fun onError(errorMsg: String?) {
|
||||
Logger.e("${SceneConstant.M_HMI}$TAG", "onError msg is:${errorMsg}")
|
||||
CallerLogger.e("${SceneConstant.M_HMI}$TAG", "onError msg is:${errorMsg}")
|
||||
isLived = false
|
||||
refreshView(isLived)
|
||||
}
|
||||
|
||||
override fun onPlaying() {
|
||||
Logger.i("${SceneConstant.M_HMI}$TAG", "onPlaying……")
|
||||
CallerLogger.i("${SceneConstant.M_HMI}$TAG", "onPlaying……")
|
||||
isLived = true
|
||||
refreshView(isLived)
|
||||
}
|
||||
|
||||
override fun onPlaRequesting() {
|
||||
Logger.w("${SceneConstant.M_HMI}$TAG", "onPlaRequesting……")
|
||||
CallerLogger.w("${SceneConstant.M_HMI}$TAG", "onPlaRequesting……")
|
||||
isLived = false
|
||||
refreshView(isLived)
|
||||
}
|
||||
}
|
||||
|
||||
interface LiveListener {
|
||||
fun onPlayError()
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.appcompat.content.res.AppCompatResources
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.commons.module.status.MogoStatusManager
|
||||
import com.mogo.eagle.core.function.api.map.roma.IMoGoRomaListener
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapIdentifyManager.romaTrigger
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapRomaListener
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import kotlinx.android.synthetic.main.view_roma_bus_bg.view.ivRomaView
|
||||
import kotlinx.android.synthetic.main.view_roma_bus_bg.view.ll_roma_bg
|
||||
|
||||
class RomaBusView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMoGoRomaListener {
|
||||
|
||||
companion object{
|
||||
private const val TAG = "RomaView"
|
||||
}
|
||||
|
||||
@Volatile
|
||||
private var romaMode = false
|
||||
|
||||
@Volatile
|
||||
private var click = true
|
||||
|
||||
private val normalRes: Int
|
||||
private val openRes: Int
|
||||
|
||||
init{
|
||||
LayoutInflater.from(context).inflate(R.layout.view_roma_bus_bg, this, true)
|
||||
val a = context.obtainStyledAttributes(
|
||||
attrs,
|
||||
R.styleable.RomaView,
|
||||
defStyleAttr,
|
||||
0
|
||||
)
|
||||
normalRes = a.getResourceId(
|
||||
R.styleable.RomaView_roma_close_bg,
|
||||
R.drawable.romabg_normal_select
|
||||
)
|
||||
openRes = a.getResourceId(
|
||||
R.styleable.RomaView_roma_open_bg,
|
||||
R.drawable.romabg_press_select_bg
|
||||
)
|
||||
a.recycle()
|
||||
if(normalRes!=0){
|
||||
ll_roma_bg.background = AppCompatResources.getDrawable(context, normalRes)
|
||||
}
|
||||
|
||||
setOnClickListener {
|
||||
if(!click){
|
||||
return@setOnClickListener
|
||||
}
|
||||
if(!MogoStatusManager.getInstance().isSocketOnLine){
|
||||
ToastUtils.showShort("长链状态异常,请检查链接后开启漫游")
|
||||
return@setOnClickListener
|
||||
}
|
||||
click = false
|
||||
romaMode = !romaMode
|
||||
//司机屏不控制乘客屏漫游,独自漫游
|
||||
romaTrigger(romaMode)
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
override fun romaStatus(status: Boolean) {
|
||||
click = true
|
||||
if (status) {
|
||||
romaMode = true
|
||||
if(openRes!=0){
|
||||
ll_roma_bg.setBackgroundResource(openRes)
|
||||
}else{
|
||||
ll_roma_bg.setBackgroundResource(R.drawable.romabg_press_select_bg)
|
||||
}
|
||||
ivRomaView.setBackgroundResource(R.drawable.roma_press_select_bg)
|
||||
} else {
|
||||
romaMode = false
|
||||
if(normalRes!=0){
|
||||
ll_roma_bg.setBackgroundResource(normalRes)
|
||||
}else{
|
||||
ll_roma_bg.setBackgroundResource(R.drawable.roma_bg_selector)
|
||||
}
|
||||
ivRomaView.setBackgroundResource(R.drawable.romafront_select_bg)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMapRomaListener.addListener(TAG, this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMapRomaListener.removeListener(TAG)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.commons.module.status.MogoStatusManager
|
||||
import com.mogo.eagle.core.function.api.map.roma.IMoGoRomaListener
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapIdentifyManager.romaTrigger
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapRomaListener
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
|
||||
class RomaPassengerView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMoGoRomaListener {
|
||||
|
||||
companion object {
|
||||
private const val TAG = "RomaPassengerView"
|
||||
}
|
||||
|
||||
@Volatile
|
||||
private var romaMode = false
|
||||
|
||||
@Volatile
|
||||
private var click = true
|
||||
|
||||
private val openRes: Int
|
||||
private val normalRes: Int
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.view_roma_passenger_bg, this, true)
|
||||
val a =
|
||||
context.obtainStyledAttributes(attrs, R.styleable.RomaPassengerView, defStyleAttr, 0)
|
||||
openRes = a.getResourceId(R.styleable.RomaPassengerView_roma_open, 0)
|
||||
normalRes = a.getResourceId(R.styleable.RomaPassengerView_roma_close, 0)
|
||||
a.recycle()
|
||||
setOnClickListener {
|
||||
if(!click){
|
||||
return@setOnClickListener
|
||||
}
|
||||
if(!MogoStatusManager.getInstance().isSocketOnLine){
|
||||
ToastUtils.showShort("长链状态异常,请检查链接后开启漫游")
|
||||
return@setOnClickListener
|
||||
}
|
||||
click = false
|
||||
romaMode = !romaMode
|
||||
romaTrigger(romaMode)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMapRomaListener.addListener(TAG, this)
|
||||
}
|
||||
|
||||
override fun romaStatus(status: Boolean) {
|
||||
click = true
|
||||
if (status) {
|
||||
romaMode = true
|
||||
if (openRes != 0) {
|
||||
setBackgroundResource(openRes)
|
||||
}
|
||||
} else {
|
||||
romaMode = false
|
||||
if (normalRes != 0) {
|
||||
setBackgroundResource(normalRes)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMapRomaListener.removeListener(TAG)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.appcompat.content.res.AppCompatResources
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.commons.module.status.MogoStatusManager
|
||||
import com.mogo.eagle.core.function.api.map.roma.IMoGoRomaListener
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapIdentifyManager.romaTrigger
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapRomaListener
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import kotlinx.android.synthetic.main.view_roma_taxi_bg.view.ivRomaView
|
||||
import kotlinx.android.synthetic.main.view_roma_taxi_bg.view.ll_roma_bg
|
||||
|
||||
class RomaTaxiView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMoGoRomaListener {
|
||||
|
||||
companion object{
|
||||
private const val TAG = "RomaView"
|
||||
}
|
||||
|
||||
@Volatile
|
||||
private var romaMode = false
|
||||
|
||||
@Volatile
|
||||
private var click = true
|
||||
|
||||
private val normalRes: Int
|
||||
private val openRes: Int
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.view_roma_taxi_bg, this, true)
|
||||
val a = context.obtainStyledAttributes(
|
||||
attrs,
|
||||
R.styleable.RomaView,
|
||||
defStyleAttr,
|
||||
0
|
||||
)
|
||||
normalRes = a.getResourceId(
|
||||
R.styleable.RomaView_roma_close_bg,
|
||||
R.drawable.romabg_normal_select
|
||||
)
|
||||
openRes = a.getResourceId(
|
||||
R.styleable.RomaView_roma_open_bg,
|
||||
R.drawable.romabg_press_select_bg
|
||||
)
|
||||
a.recycle()
|
||||
if(normalRes!=0){
|
||||
ll_roma_bg.background = AppCompatResources.getDrawable(context, normalRes)
|
||||
}
|
||||
|
||||
setOnClickListener {
|
||||
if(!click){
|
||||
return@setOnClickListener
|
||||
}
|
||||
if(!MogoStatusManager.getInstance().isSocketOnLine){
|
||||
ToastUtils.showShort("长链状态异常,请检查链接后开启漫游")
|
||||
return@setOnClickListener
|
||||
}
|
||||
click = false
|
||||
romaMode = !romaMode
|
||||
//司机屏不控制乘客屏漫游,独自漫游
|
||||
romaTrigger(romaMode)
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
override fun romaStatus(status: Boolean) {
|
||||
click = true
|
||||
if (status) {
|
||||
romaMode = true
|
||||
if(openRes!=0){
|
||||
ll_roma_bg.setBackgroundResource(openRes)
|
||||
}else{
|
||||
ll_roma_bg.setBackgroundResource(R.drawable.romabg_press_select_bg)
|
||||
}
|
||||
ivRomaView.setBackgroundResource(R.drawable.roma_press_select_bg)
|
||||
} else {
|
||||
romaMode = false
|
||||
if(normalRes!=0){
|
||||
ll_roma_bg.setBackgroundResource(normalRes)
|
||||
}else{
|
||||
ll_roma_bg.setBackgroundResource(R.drawable.roma_bg_selector)
|
||||
}
|
||||
ivRomaView.setBackgroundResource(R.drawable.romafront_select_bg)
|
||||
}
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerMapRomaListener.addListener(TAG, this)
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerMapRomaListener.removeListener(TAG)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -2,23 +2,28 @@ package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.widget.ImageView
|
||||
import android.widget.LinearLayout
|
||||
import android.widget.TextView
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.config.HmiBuildConfig
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType
|
||||
import com.mogo.eagle.core.data.enums.TrafficLightEnum
|
||||
import com.mogo.eagle.core.function.api.datacenter.union.IMoGoTrafficLightListener
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IViewControlListener
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IViewControlListener.Companion.TrafficLightView_TAG
|
||||
import com.mogo.eagle.core.function.api.datacenter.union.IMoGoTrafficLightListener
|
||||
import com.mogo.eagle.core.function.api.setting.IMoGoSkinModeChangeListener
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiViewControlListenerManager
|
||||
import com.mogo.eagle.core.function.call.setting.CallerSkinModeListenerManager
|
||||
import com.mogo.eagle.core.function.call.v2x.CallerTrafficLightListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_HMI
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import kotlinx.android.synthetic.main.hmi_view_traffic_light.view.*
|
||||
|
||||
/**
|
||||
* 新版红绿灯view
|
||||
@@ -27,7 +32,8 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
context: Context?,
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : LinearLayout(context, attrs, defStyleAttr), IViewControlListener, IMoGoTrafficLightListener {
|
||||
) : LinearLayout(context, attrs, defStyleAttr), IViewControlListener, IMoGoTrafficLightListener,
|
||||
IMoGoSkinModeChangeListener {
|
||||
|
||||
companion object {
|
||||
private const val TAG = "SingleTrafficLightView"
|
||||
@@ -49,6 +55,7 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
mLightSourceTV = findViewById(R.id.hmi_traffic_light_source)
|
||||
mLightSourceDivider = findViewById(R.id.hmi_traffic_light_divider)
|
||||
|
||||
CallerSkinModeListenerManager.addListener(TAG, this)
|
||||
CallerTrafficLightListenerManager.addListener(TAG, this)
|
||||
CallerHmiViewControlListenerManager.addListener(TrafficLightView_TAG, this)
|
||||
}
|
||||
@@ -60,10 +67,28 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerSkinModeListenerManager.removeListener(TAG)
|
||||
CallerTrafficLightListenerManager.removeListener(TAG)
|
||||
CallerHmiViewControlListenerManager.removeListener(TrafficLightView_TAG)
|
||||
}
|
||||
|
||||
override fun onSkinModeChange(skinMode: Int) {
|
||||
ThreadUtils.runOnUiThread {
|
||||
when (skinMode) {
|
||||
0 -> {
|
||||
hmi_traffic_light_bg.setBackgroundResource(R.drawable.traffic_light_bg)
|
||||
hmi_traffic_light_source.setTextColor(resources.getColor(R.color.color_FFFFFF))
|
||||
hmi_traffic_light_divider.setBackgroundColor(resources.getColor(R.color.color_FFFFFF))
|
||||
}
|
||||
1 -> {
|
||||
hmi_traffic_light_bg.setBackgroundResource(R.drawable.traffic_light_bg_day_light)
|
||||
hmi_traffic_light_source.setTextColor(resources.getColor(R.color.color_2D3E5F))
|
||||
hmi_traffic_light_divider.setBackgroundColor(resources.getColor(R.color.color_2D3E5F))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 展示红绿灯预警
|
||||
*
|
||||
@@ -72,9 +97,12 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
*/
|
||||
override fun showTrafficLight(checkLightId: TrafficLightEnum, lightSource: DataSourceType) {
|
||||
super.showTrafficLight(checkLightId, lightSource)
|
||||
mCurrentLightId = checkLightId
|
||||
if (!HmiBuildConfig.isShowTrafficLightView) {
|
||||
updateTrafficLightIcon(checkLightId, lightSource)
|
||||
UiThreadHandler.post {
|
||||
CallerLogger.d("$M_HMI$TAG","update checkLightId:$checkLightId, lightSource: $lightSource")
|
||||
mCurrentLightId = checkLightId
|
||||
if (!HmiBuildConfig.isShowTrafficLightView) {
|
||||
updateTrafficLightIcon(checkLightId, lightSource)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -93,29 +121,26 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
super.disableTrafficLightCountDown()
|
||||
UiThreadHandler.post {
|
||||
// 小巴车的司机端需要展示红绿灯信号来源
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
&& AppIdentityModeUtils.isBus(FunctionBuildConfig.appIdentityMode)
|
||||
) {
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width = context.resources.getDimension(R.dimen.dp_325).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightSourceTV!!.visibility = VISIBLE
|
||||
mLightSourceDivider!!.visibility = VISIBLE
|
||||
mLightTimeTV!!.visibility = GONE
|
||||
mLightSourceTV!!.setPadding(0, 0, 75, 0)
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.dp_310).toInt()
|
||||
} else {
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_icon_size).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightTimeTV!!.visibility = GONE
|
||||
mLightSourceDivider!!.visibility = View.GONE
|
||||
mLightSourceTV!!.visibility = View.GONE
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.dp_124).toInt()
|
||||
}
|
||||
// if(AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
// && AppIdentityModeUtils.isBus(FunctionBuildConfig.appIdentityMode)){
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width = context.resources.getDimension(R.dimen.dp_325).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightSourceTV!!.visibility = VISIBLE
|
||||
mLightSourceDivider!!.visibility = VISIBLE
|
||||
mLightTimeTV!!.visibility = GONE
|
||||
mLightSourceTV!!.setPadding(0, 0, 75, 0)
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.dp_310).toInt()
|
||||
// }else{
|
||||
// val lp = this.layoutParams as MarginLayoutParams
|
||||
// lp.width = context.resources.getDimension(R.dimen.hmi_traffic_light_icon_size).toInt()
|
||||
// this.layoutParams = lp
|
||||
// mLightTimeTV!!.visibility = GONE
|
||||
// mLightSourceDivider!!.visibility = View.GONE
|
||||
// mLightSourceTV!!.visibility = View.GONE
|
||||
// mLightIconBG!!.layoutParams.width = context.resources.getDimension(R.dimen.dp_124).toInt()
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -201,68 +226,63 @@ class SingleTrafficLightView @JvmOverloads constructor(
|
||||
* 更新红绿灯icon
|
||||
*
|
||||
* @param lightId 0-都是默认,1-红,2-黄,3-绿
|
||||
* @param lightSource 1:云端下发;2:自车感知
|
||||
* @param lightSource 1:云端下发;2:自车感知; 3:OBU
|
||||
*/
|
||||
private fun updateTrafficLightIcon(lightId: TrafficLightEnum, lightSource: DataSourceType) {
|
||||
UiThreadHandler.post {
|
||||
when (lightId) {
|
||||
TrafficLightEnum.RED -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_light_red_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
TrafficLightEnum.YELLOW -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_lightyellow_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
TrafficLightEnum.GREEN -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_light_green_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
else -> this@SingleTrafficLightView.visibility = GONE
|
||||
when (lightId) {
|
||||
TrafficLightEnum.RED -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_light_red_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
when (lightSource) {
|
||||
DataSourceType.AICLOUD -> {
|
||||
mLightSourceTV!!.text = "云端下发"
|
||||
}
|
||||
DataSourceType.TELEMATIC -> {
|
||||
mLightSourceTV!!.text = "自车感知"
|
||||
}
|
||||
DataSourceType.OBU -> {
|
||||
mLightSourceTV!!.text = "OBU"
|
||||
}
|
||||
else -> {
|
||||
mLightSourceTV!!.visibility = GONE
|
||||
}
|
||||
TrafficLightEnum.YELLOW -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_lightyellow_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
TrafficLightEnum.GREEN -> {
|
||||
mLightIconIV!!.setBackgroundResource(R.drawable.hmi_light_green_nor)
|
||||
this@SingleTrafficLightView.visibility = VISIBLE
|
||||
}
|
||||
else -> this@SingleTrafficLightView.visibility = GONE
|
||||
}
|
||||
when (lightSource) {
|
||||
DataSourceType.AICLOUD -> {
|
||||
mLightSourceTV!!.text = "云端下发"
|
||||
}
|
||||
DataSourceType.TELEMATIC -> {
|
||||
mLightSourceTV!!.text = "自车感知"
|
||||
}
|
||||
DataSourceType.OBU -> {
|
||||
mLightSourceTV!!.text = "OBU"
|
||||
}
|
||||
else -> {
|
||||
mLightSourceTV!!.visibility = GONE
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun resetView() {
|
||||
// 小巴车的司机端需要展示红绿灯信号来源
|
||||
if (AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
&& AppIdentityModeUtils.isBus(FunctionBuildConfig.appIdentityMode)
|
||||
) {
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_bus_layout_width).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightTimeTV!!.visibility = View.VISIBLE
|
||||
mLightSourceDivider!!.visibility = View.VISIBLE
|
||||
mLightSourceTV!!.visibility = View.VISIBLE
|
||||
mLightSourceTV!!.setPadding(0, 0, 0, 0)
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_bus_bg_width).toInt()
|
||||
} else {
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_layout_width).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightTimeTV!!.visibility = View.VISIBLE
|
||||
mLightSourceDivider!!.visibility = View.GONE
|
||||
mLightSourceTV!!.visibility = View.GONE
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_bg_width).toInt()
|
||||
}
|
||||
// 小巴车的司机端需要展示红绿灯信号来源 ,由于需要知道来源,这里不在限制
|
||||
// if(AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)
|
||||
// && AppIdentityModeUtils.isBus(FunctionBuildConfig.appIdentityMode)){
|
||||
val lp = this.layoutParams as MarginLayoutParams
|
||||
lp.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_bus_layout_width).toInt()
|
||||
this.layoutParams = lp
|
||||
mLightTimeTV!!.visibility = View.VISIBLE
|
||||
mLightSourceDivider!!.visibility = View.VISIBLE
|
||||
mLightSourceTV!!.visibility = View.VISIBLE
|
||||
mLightSourceTV!!.setPadding(0, 0, 0, 0)
|
||||
mLightIconBG!!.layoutParams.width =
|
||||
context.resources.getDimension(R.dimen.hmi_traffic_light_bus_bg_width).toInt()
|
||||
// }else{
|
||||
// val lp = this.layoutParams as MarginLayoutParams
|
||||
// lp.width = context.resources.getDimension(R.dimen.hmi_traffic_light_layout_width).toInt()
|
||||
// this.layoutParams = lp
|
||||
// mLightTimeTV!!.visibility = View.VISIBLE
|
||||
// mLightSourceDivider!!.visibility = View.GONE
|
||||
// mLightSourceTV!!.visibility = View.GONE
|
||||
// mLightIconBG!!.layoutParams.width = context.resources.getDimension(R.dimen.hmi_traffic_light_bg_width).toInt()
|
||||
// }
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,87 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget;
|
||||
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.widget.AppCompatImageView;
|
||||
|
||||
import com.bumptech.glide.Priority;
|
||||
import com.bumptech.glide.load.engine.DiskCacheStrategy;
|
||||
import com.bumptech.glide.request.RequestOptions;
|
||||
import com.bumptech.glide.request.target.CustomTarget;
|
||||
import com.bumptech.glide.request.transition.Transition;
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoSweeperFutianBackCameraVideoListener;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerSweeperFutianBackCameraVideoListenerManager;
|
||||
import com.mogo.eagle.core.utilcode.mogo.glide.GlideApp;
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils;
|
||||
|
||||
/**
|
||||
* 清扫车摄像头展示View
|
||||
*/
|
||||
public class SweeperVideoView extends AppCompatImageView implements IMoGoSweeperFutianBackCameraVideoListener {
|
||||
private static final String TAG = SweeperVideoView.class.getSimpleName();
|
||||
private final RequestOptions requestOptions = new RequestOptions()
|
||||
.priority(Priority.HIGH)
|
||||
.skipMemoryCache(true)
|
||||
.diskCacheStrategy(DiskCacheStrategy.NONE)
|
||||
.dontAnimate();
|
||||
|
||||
public SweeperVideoView(@NonNull Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
public SweeperVideoView(@NonNull Context context, @Nullable AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
public SweeperVideoView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
|
||||
super(context, attrs, defStyleAttr);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onAttachedToWindow() {
|
||||
super.onAttachedToWindow();
|
||||
CallerSweeperFutianBackCameraVideoListenerManager.INSTANCE.addListener(TAG, this);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow();
|
||||
CallerSweeperFutianBackCameraVideoListenerManager.INSTANCE.removeListener(this);
|
||||
}
|
||||
|
||||
private final CustomTarget<Bitmap> target = new CustomTarget<Bitmap>() {
|
||||
@Override
|
||||
public void onResourceReady(@NonNull Bitmap resource, @Nullable Transition<? super Bitmap> transition) {
|
||||
//回调内容
|
||||
if (!resource.isRecycled()) {
|
||||
SweeperVideoView.this.setImageBitmap(resource);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoadCleared(@Nullable Drawable placeholder) {
|
||||
//这个方法在target被回收时调用,如果在除了imageView以外的地方引用了imageView中的bitmap,在这里清除引用以避免崩溃
|
||||
}
|
||||
};
|
||||
|
||||
@Override
|
||||
public void onSweeperFutianBackCameraVideo(@NonNull byte[] data) {
|
||||
ThreadUtils.runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
GlideApp.with(SweeperVideoView.this)
|
||||
.asBitmap()
|
||||
.load(data)
|
||||
.placeholder(SweeperVideoView.this.getDrawable())
|
||||
.apply(requestOptions)
|
||||
.into(target);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -23,10 +23,7 @@ import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.map.OfflineMapDialog
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_HMI
|
||||
import com.mogo.eagle.core.utilcode.util.AppUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.eagle.core.utilcode.util.*
|
||||
import kotlinx.android.synthetic.main.view_system_version.view.*
|
||||
|
||||
|
||||
@@ -146,6 +143,7 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
ToastUtils.showShort(resources.getString(R.string.location_try_again))
|
||||
} else {// 拿到了高精的经纬度
|
||||
val dialog = OfflineMapDialog(context)
|
||||
CallerLogger.i("$M_HMI$$TAG", "location lon is:${location?.longitude}, lat is:${location?.latitude}")
|
||||
dialog.location = location
|
||||
dialog.show()
|
||||
}
|
||||
@@ -165,7 +163,7 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
if(AdUpgradeStateHelper.isConfirmUpgrade()){
|
||||
//将角标改为“下载中”
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_downloading)
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
//设置状态为不可升级
|
||||
AdUpgradeStateHelper.setUpgradeableStatus(false)
|
||||
}
|
||||
@@ -216,48 +214,48 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
|
||||
}
|
||||
}
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
}
|
||||
AdUpgradeStateHelper.isDownloadFailed(status) -> {
|
||||
//下载失败,将状态设为“最新版”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_latest_version)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
AdUpgradeStateHelper.isDownloadFinish(status) ->{
|
||||
//升级中,将状态设为“升级中”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_upgrading)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
AdUpgradeStateHelper.isUpgrading(status) ->{
|
||||
//升级中,将状态设为“升级中”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_upgrading)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
AdUpgradeStateHelper.isUpgradeSuccess(status) -> {
|
||||
//升级成功,将状态设为“最新版”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_latest_version)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
AdUpgradeStateHelper.isUpgradeFailed(status) -> {
|
||||
//升级失败,将状态设为“升级失败”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_upgrade_failed)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
else -> {
|
||||
//其他状态,均显示“最新版”,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_latest_version)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setConfirmUpgrade(false)
|
||||
}
|
||||
}
|
||||
@@ -292,7 +290,8 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
tvAdVersionContent?.let {
|
||||
// it.text = AdasManager.getInstance().getAdasConfig().getDockVersion())
|
||||
if (!dockerVersion.isNullOrEmpty()) {
|
||||
it.text = dockerVersion
|
||||
// it.text = dockerVersion
|
||||
it.text = ParseVersionUtils.parseVersion(dockerVersion)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -353,13 +352,13 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
//有更新任务,将状态设为“可升级”角标,并隐藏进度条
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_upgradeable)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_upgradeable_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_upgradeable_background)
|
||||
AdUpgradeStateHelper.setUpgradeableStatus(true)
|
||||
}else{
|
||||
ToastUtils.showLong("已是最新版本")
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_latest_version)
|
||||
adCircularProgressView?.visibility = View.GONE
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
AdUpgradeStateHelper.setUpgradeableStatus(false)
|
||||
}
|
||||
}
|
||||
@@ -370,7 +369,7 @@ class SystemVersionView @JvmOverloads constructor(
|
||||
override fun pushServerConfirm() {
|
||||
//将角标改为“下载中”
|
||||
ivAdStatus?.setImageResource(R.drawable.icon_downloading)
|
||||
ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
// ivAdVersion?.setBackgroundResource(R.drawable.version_latest_background)
|
||||
//设置状态为不可升级
|
||||
AdUpgradeStateHelper.setUpgradeableStatus(false)
|
||||
//设置进度条为隐藏
|
||||
|
||||
@@ -209,9 +209,6 @@ public class TrafficDataView extends ConstraintLayout implements
|
||||
if (speedTextView != null) {
|
||||
speedTextView.setText(String.valueOf(newSpeed));
|
||||
}
|
||||
if (speedImage != null) {
|
||||
speedImage.setBackgroundResource(newSpeed > 60 ? R.drawable.traffic_data_speed_warning : R.drawable.traffic_data_speed);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,92 +0,0 @@
|
||||
package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.animation.Animator
|
||||
import android.animation.Animator.AnimatorListener
|
||||
import android.animation.AnimatorSet
|
||||
import android.animation.ObjectAnimator
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.enums.EventTypeEnumNew
|
||||
import com.mogo.eagle.core.data.enums.WarningDirectionEnum
|
||||
import com.mogo.eagle.core.function.api.hmi.warning.IV2XEventListener
|
||||
import com.mogo.eagle.core.function.call.v2x.CallerV2XWarningListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import kotlinx.android.synthetic.main.view_v2x_warning_fog.view.*
|
||||
|
||||
class V2XFogEventView(context: Context, attrs: AttributeSet) :
|
||||
ConstraintLayout(context, attrs), IV2XEventListener {
|
||||
|
||||
companion object {
|
||||
private const val TAG = "V2XFogEventView"
|
||||
}
|
||||
|
||||
private val animatorSet = AnimatorSet()
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.view_v2x_warning_fog, this, true)
|
||||
val animator1 = ObjectAnimator.ofFloat(iv_wu1, "alpha", 0f, 1f, 0f)
|
||||
val animator2 = ObjectAnimator.ofFloat(iv_wu1, "translationX", -500f, 100f, 300f)
|
||||
val animator3 = ObjectAnimator.ofFloat(iv_wu1, "scaleX", 1f, 1.5f, 2f)
|
||||
val animator4 = ObjectAnimator.ofFloat(iv_wu1, "scaleY", 1f, 1.5f, 2f)
|
||||
val animator5 = ObjectAnimator.ofFloat(iv_wu2, "alpha", 0f, 1f, 0f)
|
||||
val animator6 = ObjectAnimator.ofFloat(iv_wu2, "translationX", 500f, -100f, -300f)
|
||||
val animator7 = ObjectAnimator.ofFloat(iv_wu2, "scaleX", 1f, 1.5f, 2f)
|
||||
val animator8 = ObjectAnimator.ofFloat(iv_wu2, "scaleY", 1f, 1.5f, 2f)
|
||||
animatorSet.playTogether(
|
||||
animator1,
|
||||
animator2,
|
||||
animator3,
|
||||
animator4,
|
||||
animator5,
|
||||
animator6,
|
||||
animator7,
|
||||
animator8
|
||||
)
|
||||
animatorSet.duration = 5000
|
||||
animatorSet.addListener(object : AnimatorListener{
|
||||
override fun onAnimationStart(animation: Animator?) {
|
||||
visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
override fun onAnimationEnd(animation: Animator?) {
|
||||
visibility = View.GONE
|
||||
}
|
||||
|
||||
override fun onAnimationCancel(animation: Animator?) {
|
||||
visibility = View.GONE
|
||||
}
|
||||
|
||||
override fun onAnimationRepeat(animation: Animator?) {
|
||||
|
||||
}
|
||||
|
||||
})
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
CallerV2XWarningListenerManager.addListener(TAG, this)
|
||||
}
|
||||
|
||||
override fun show(v2xType: String, direction: WarningDirectionEnum, time: Long) {
|
||||
ThreadUtils.runOnUiThread {
|
||||
if(v2xType == EventTypeEnumNew.FOURS_FOG.poiType){
|
||||
animatorSet.start()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun dismiss(direction: WarningDirectionEnum) {
|
||||
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerV2XWarningListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -18,6 +18,7 @@ import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import kotlinx.android.synthetic.main.view_v2x_warning.view.*
|
||||
import java.util.concurrent.atomic.AtomicReference
|
||||
|
||||
|
||||
class V2XWarningView @JvmOverloads constructor(
|
||||
@@ -35,6 +36,8 @@ class V2XWarningView @JvmOverloads constructor(
|
||||
showWarning(ALERT_WARNING_NON)
|
||||
}
|
||||
|
||||
private val oldDirection = AtomicReference<WarningDirectionEnum>()
|
||||
|
||||
init {
|
||||
LayoutInflater.from(context).inflate(R.layout.view_v2x_warning, this, true)
|
||||
}
|
||||
@@ -45,18 +48,11 @@ class V2XWarningView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
override fun show(v2xType: String, direction: WarningDirectionEnum, time: Long) {
|
||||
ThreadUtils.runOnUiThread {
|
||||
if (direction != ALERT_WARNING_NON) {
|
||||
showWarning(direction)
|
||||
}
|
||||
}
|
||||
|
||||
showWarning(direction, time)
|
||||
}
|
||||
|
||||
override fun dismiss(direction: WarningDirectionEnum) {
|
||||
ThreadUtils.runOnUiThread {
|
||||
dismissWarning(direction)
|
||||
}
|
||||
dismissWarning(direction)
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -65,12 +61,18 @@ class V2XWarningView @JvmOverloads constructor(
|
||||
* @see WarningDirectionEnum
|
||||
*/
|
||||
private fun showWarning(direction: WarningDirectionEnum, time: Long = ALL_CLOSE_TIMER) {
|
||||
UiThreadHandler.post {
|
||||
// 如果传入的不是关闭显示,则设置倒计时,定时关闭红框警示
|
||||
if (direction != ALERT_WARNING_NON) {
|
||||
removeCallbacks(closeWarningTask)
|
||||
postDelayed(closeWarningTask, time)
|
||||
}
|
||||
// 如果传入的不是关闭显示,则设置倒计时,定时关闭红框警示
|
||||
if (oldDirection.get() == direction) {
|
||||
removeCallbacks(closeWarningTask)
|
||||
postDelayed(closeWarningTask, time)
|
||||
return
|
||||
}
|
||||
if (direction != ALERT_WARNING_NON) {
|
||||
oldDirection.set(direction)
|
||||
removeCallbacks(closeWarningTask)
|
||||
postDelayed(closeWarningTask, time)
|
||||
}
|
||||
post {
|
||||
when (direction) {
|
||||
ALERT_WARNING_NON -> {
|
||||
// nothing
|
||||
@@ -166,12 +168,16 @@ class V2XWarningView @JvmOverloads constructor(
|
||||
hmiWarningRightBottomImg.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
val alphaAnimation = AlphaAnimation(0f, 0.88f)
|
||||
alphaAnimation.duration = 600
|
||||
alphaAnimation.interpolator = LinearInterpolator()
|
||||
alphaAnimation.repeatCount = Animation.INFINITE
|
||||
alphaAnimation.repeatMode = Animation.REVERSE
|
||||
startAnimation(alphaAnimation)
|
||||
if (direction == ALERT_WARNING_NON) {
|
||||
dismissWarning(ALERT_WARNING_ALL)
|
||||
} else {
|
||||
val alphaAnimation = AlphaAnimation(0f, 0.88f)
|
||||
alphaAnimation.duration = 600
|
||||
alphaAnimation.interpolator = LinearInterpolator()
|
||||
alphaAnimation.repeatCount = Animation.INFINITE
|
||||
alphaAnimation.repeatMode = Animation.REVERSE
|
||||
startAnimation(alphaAnimation)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -180,51 +186,53 @@ class V2XWarningView @JvmOverloads constructor(
|
||||
return
|
||||
}
|
||||
removeCallbacks(closeWarningTask)
|
||||
when (direction) {
|
||||
ALERT_WARNING_TOP -> {
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_RIGHT -> {
|
||||
hmiWarningRightImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM -> {
|
||||
hmiWarningBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_LEFT -> {
|
||||
hmiWarningLeftImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_TOP_RIGHT -> {
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM_RIGHT -> {
|
||||
hmiWarningRightBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM_LEFT -> {
|
||||
hmiWarningLeftBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_TOP_LEFT -> {
|
||||
hmiWarningLeftTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_ALL -> {
|
||||
hmiWarningTopImg.visibility = View.GONE
|
||||
hmiWarningRightImg.visibility = View.GONE
|
||||
hmiWarningBottomImg.visibility = View.GONE
|
||||
hmiWarningLeftImg.visibility = View.GONE
|
||||
hmiWarningLeftTopImg.visibility = View.GONE
|
||||
hmiWarningLeftBottomImg.visibility = View.GONE
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
hmiWarningRightBottomImg.visibility = View.GONE
|
||||
}
|
||||
else -> {
|
||||
CallerLogger.d("$M_HMI$TAG", "Not Support Direction")
|
||||
post {
|
||||
when (direction) {
|
||||
ALERT_WARNING_TOP -> {
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_RIGHT -> {
|
||||
hmiWarningRightImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM -> {
|
||||
hmiWarningBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_LEFT -> {
|
||||
hmiWarningLeftImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_TOP_RIGHT -> {
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM_RIGHT -> {
|
||||
hmiWarningRightBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_BOTTOM_LEFT -> {
|
||||
hmiWarningLeftBottomImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_TOP_LEFT -> {
|
||||
hmiWarningLeftTopImg.visibility = View.GONE
|
||||
}
|
||||
ALERT_WARNING_ALL -> {
|
||||
hmiWarningTopImg.visibility = View.GONE
|
||||
hmiWarningRightImg.visibility = View.GONE
|
||||
hmiWarningBottomImg.visibility = View.GONE
|
||||
hmiWarningLeftImg.visibility = View.GONE
|
||||
hmiWarningLeftTopImg.visibility = View.GONE
|
||||
hmiWarningLeftBottomImg.visibility = View.GONE
|
||||
hmiWarningRightTopImg.visibility = View.GONE
|
||||
hmiWarningRightBottomImg.visibility = View.GONE
|
||||
}
|
||||
else -> {
|
||||
CallerLogger.d("$M_HMI$TAG", "Not Support Direction")
|
||||
}
|
||||
}
|
||||
clearAnimation()
|
||||
this.oldDirection.set(null)
|
||||
}
|
||||
clearAnimation()
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
CallerV2XWarningListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -9,6 +9,7 @@ import android.os.Handler
|
||||
import android.os.Message
|
||||
import android.util.AttributeSet
|
||||
import androidx.appcompat.widget.AppCompatImageView
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.function.api.setting.IMoGoSkinModeChangeListener
|
||||
import com.mogo.eagle.core.function.call.setting.CallerSkinModeListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
@@ -35,9 +36,9 @@ class WifiStateView @JvmOverloads constructor(
|
||||
|
||||
override fun handleMessage(msg: Message) {
|
||||
super.handleMessage(msg)
|
||||
val wifiStateView = stateViewWeakReference?.get()
|
||||
wifiStateView?.updateView(msg.what) {
|
||||
wifiStateView.setImageResource(it)
|
||||
val view = stateViewWeakReference?.get()
|
||||
view?.updateView(msg.what) {
|
||||
view.setImageResource(it)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -46,9 +47,6 @@ class WifiStateView @JvmOverloads constructor(
|
||||
private var wifiManager: WifiManager? = null
|
||||
private var wifiHandler: WifiHandler? = null
|
||||
|
||||
@Volatile
|
||||
private var mSkinMode: Int = 0
|
||||
|
||||
@Volatile
|
||||
private var level: Int = 0
|
||||
|
||||
@@ -96,12 +94,11 @@ class WifiStateView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
override fun onSkinModeChange(skinMode: Int) {
|
||||
mSkinMode = skinMode
|
||||
wifiHandler?.sendEmptyMessage(level)
|
||||
}
|
||||
|
||||
fun updateView(wifiState: Int, resId: ((Int) -> Unit)) {
|
||||
when (mSkinMode) {
|
||||
when (FunctionBuildConfig.skinMode) {
|
||||
0 -> {
|
||||
when (wifiState) {
|
||||
-1 -> resId.invoke(R.drawable.wifi_light_state_close)
|
||||
@@ -114,7 +111,7 @@ class WifiStateView @JvmOverloads constructor(
|
||||
}
|
||||
1 -> {
|
||||
when (wifiState) {
|
||||
-1 -> resId.invoke(R.drawable.wifi_light_state_close)
|
||||
-1 -> resId.invoke(R.drawable.wifi_dark_state_one)
|
||||
0 -> resId.invoke(R.drawable.wifi_dark_state_one)
|
||||
1 -> resId.invoke(R.drawable.wifi_dark_state_two)
|
||||
2 -> resId.invoke(R.drawable.wifi_dark_state_three)
|
||||
|
||||
@@ -1,55 +0,0 @@
|
||||
package com.mogo.eagle.core.function.main;
|
||||
|
||||
import android.animation.AnimatorSet;
|
||||
import android.animation.ObjectAnimator;
|
||||
import android.content.res.Resources;
|
||||
import android.util.DisplayMetrics;
|
||||
import android.view.View;
|
||||
|
||||
import com.mogo.eagle.core.function.hmi.R;
|
||||
|
||||
|
||||
/**
|
||||
* created by wujifei on 2021/3/30 14:05
|
||||
* describe:
|
||||
*/
|
||||
public class DisplayEffectsHelper {
|
||||
private volatile static DisplayEffectsHelper instance = null;
|
||||
private AnimatorSet animatorSet;
|
||||
|
||||
public static DisplayEffectsHelper getInstance() {
|
||||
if (instance == null) {
|
||||
synchronized (DisplayEffectsHelper.class) {
|
||||
if (instance == null) {
|
||||
instance = new DisplayEffectsHelper();
|
||||
}
|
||||
}
|
||||
}
|
||||
return instance;
|
||||
}
|
||||
|
||||
public void init(View rootView) {
|
||||
View view1 = rootView.findViewById(R.id.iv_wu1);
|
||||
View view2 = rootView.findViewById(R.id.iv_wu2);
|
||||
ObjectAnimator animator1 = ObjectAnimator.ofFloat(view1, "alpha", 0f, 1f, 0f);
|
||||
ObjectAnimator animator2 = ObjectAnimator.ofFloat(view1, "translationX", -500, 100f, 300f);
|
||||
ObjectAnimator animator3 = ObjectAnimator.ofFloat(view1, "scaleX", 1f, 1.5f, 2f);
|
||||
ObjectAnimator animator4 = ObjectAnimator.ofFloat(view1, "scaleY", 1f, 1.5f, 2f);
|
||||
ObjectAnimator animator5 = ObjectAnimator.ofFloat(view2, "alpha", 0f, 1f, 0f);
|
||||
ObjectAnimator animator6 = ObjectAnimator.ofFloat(view2, "translationX", 500, -100f, -300f);
|
||||
ObjectAnimator animator7 = ObjectAnimator.ofFloat(view2, "scaleX", 1f, 1.5f, 2f);
|
||||
ObjectAnimator animator8 = ObjectAnimator.ofFloat(view2, "scaleY", 1f, 1.5f, 2f);
|
||||
animatorSet = new AnimatorSet();
|
||||
animatorSet.playTogether(animator1, animator2, animator3, animator4, animator5, animator6, animator7, animator8);
|
||||
animatorSet.setDuration(5000);
|
||||
}
|
||||
|
||||
public void display() {
|
||||
animatorSet.start();
|
||||
}
|
||||
|
||||
private float dp2px(float dp) {
|
||||
DisplayMetrics metrics = Resources.getSystem().getDisplayMetrics();
|
||||
return dp * metrics.density;
|
||||
}
|
||||
}
|
||||
@@ -112,6 +112,7 @@ open class MainActivity : MvpActivity<MainView?, MainPresenter?>(), MainView,
|
||||
}
|
||||
|
||||
|
||||
// todo 优化 车聊聊
|
||||
private fun injectFloatView() {
|
||||
val decorView = this.window.decorView as? FrameLayout ?: return
|
||||
val contentView =
|
||||
|
||||
@@ -27,8 +27,7 @@ import com.mogo.eagle.core.function.call.setting.CallerSkinModeListenerManager;
|
||||
import com.mogo.eagle.core.function.hmi.R;
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils;
|
||||
import com.mogo.eagle.core.utilcode.util.MultiDisplayUtils;
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils;
|
||||
import com.rousetime.android_startup.model.CostTimesModel;
|
||||
import com.zhjt.service.chain.ChainLog;
|
||||
import com.zhjt.service.chain.TracingConstants;
|
||||
@@ -49,6 +48,8 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
private final static Handler handlerV2XEvent = new Handler();
|
||||
private static Runnable runnableV2XEvent;
|
||||
|
||||
private static long lastKeyDownTimeMillis;
|
||||
|
||||
@Override
|
||||
protected void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
@@ -59,7 +60,7 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
ActivityUtils.setDefaultL(this);
|
||||
//ActivityUtils.setDefaultL(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -185,9 +186,25 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
|
||||
@Override
|
||||
public boolean onKeyDown(int keyCode, KeyEvent event) {
|
||||
long currentTimeMillis = System.currentTimeMillis();
|
||||
if (keyCode == KeyEvent.KEYCODE_BACK) {
|
||||
if (currentTimeMillis - lastKeyDownTimeMillis < 2000) {
|
||||
finish();
|
||||
System.exit(0);
|
||||
} else {
|
||||
ToastUtils.showLong(R.string.hint_exit_app_again);
|
||||
lastKeyDownTimeMillis = System.currentTimeMillis();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
return super.onKeyDown(keyCode, event);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBackPressed() {
|
||||
super.onBackPressed();
|
||||
}
|
||||
|
||||
/**
|
||||
* 魔方按键分发
|
||||
*
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
package com.mogo.eagle.core.function.main;
|
||||
|
||||
import static com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.M_HMI;
|
||||
import static com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.M_MAIN;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Process;
|
||||
|
||||
import com.bytedance.boost_multidex.BoostMultiDex;
|
||||
import com.mogo.cloud.socket.SocketBuildConfig;
|
||||
@@ -20,7 +19,6 @@ import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager;
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils;
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppLaunchTimeUtils;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
import com.mogo.eagle.core.utilcode.util.ProcessUtils;
|
||||
|
||||
import java.lang.reflect.Field;
|
||||
|
||||
@@ -48,12 +46,6 @@ public abstract class MainMoGoApplication extends AbsMogoApplication {
|
||||
CallerDevaToolsManager.INSTANCE.updateUpgradeProgress();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean shouldInit() {
|
||||
CallerLogger.INSTANCE.w(M_HMI + TAG, "evaluate shouldInit() with: " + ProcessUtils.getProcessName(Process.myPid()));
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* 初始化异常采集配置
|
||||
*/
|
||||
@@ -79,7 +71,7 @@ public abstract class MainMoGoApplication extends AbsMogoApplication {
|
||||
}
|
||||
|
||||
private void initModules() {
|
||||
CallerLogger.INSTANCE.d(M_HMI + TAG, "initModules");
|
||||
CallerLogger.INSTANCE.d(M_MAIN + TAG, "initModules");
|
||||
// OBU 模块
|
||||
MogoModulePaths.addModuleFunctionServer(new MogoModule(MogoServicePaths.PATH_V2X_OBU_MOGO, "IMoGoObuProvider"));
|
||||
// BIZ
|
||||
@@ -91,7 +83,7 @@ public abstract class MainMoGoApplication extends AbsMogoApplication {
|
||||
// 后置 地图数据收集模块
|
||||
MogoModulePaths.addModuleFunctionServer(new MogoModule(MogoServicePaths.PATH_MAP_DATA_COLLECT_PROVIDER, "MoGoMapDataCollector"));
|
||||
}
|
||||
CallerLogger.INSTANCE.i(M_HMI + TAG, "App launch timer cost " + (System.currentTimeMillis() - start) + "ms");
|
||||
CallerLogger.INSTANCE.i(M_MAIN + TAG, "App launch timer cost " + (System.currentTimeMillis() - start) + "ms");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:fromDegrees="0"
|
||||
android:pivotX="50%"
|
||||
android:pivotY="50%"
|
||||
android:toDegrees="360"
|
||||
android:drawable="@drawable/icon_loading_live">
|
||||
</rotate>
|
||||
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 1.7 KiB |
|
After Width: | Height: | Size: 20 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 784 KiB |
|
After Width: | Height: | Size: 5.1 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/romabg_press_select_bg" android:state_focused="true" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/romabg_press_select_bg" android:state_focused="false" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/romabg_press_select_bg" android:state_selected="true" />
|
||||
<item android:drawable="@drawable/romabg_press_select_bg" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/romabg_normal_select" />
|
||||
</selector>
|
||||
|
After Width: | Height: | Size: 5.4 KiB |
|
After Width: | Height: | Size: 6.1 KiB |
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="oval">
|
||||
<gradient
|
||||
android:startColor="#323C6F"
|
||||
android:endColor="#323C6F"
|
||||
android:angle="315"
|
||||
/>
|
||||
<size
|
||||
android:width="120dp"
|
||||
android:height="120dp"
|
||||
/>
|
||||
</shape>
|
||||
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="oval">
|
||||
<gradient
|
||||
android:startColor="#029DFF"
|
||||
android:endColor="#0056FF"
|
||||
android:angle="225"
|
||||
/>
|
||||
<size
|
||||
android:width="120dp"
|
||||
android:height="120dp"
|
||||
/>
|
||||
</shape>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/roma_press_select_bg" android:state_focused="true" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/roma_press_select_bg" android:state_focused="false" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/roma_press_select_bg" android:state_selected="true" />
|
||||
<item android:drawable="@drawable/roma_press_select_bg" android:state_focused="true" />
|
||||
<item android:drawable="@drawable/roma_normal_select_bg" />
|
||||
</selector>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<solid android:color="#CCFFFFFF"/>
|
||||
<corners android:radius="@dimen/hmi_traffic_light_layout_corner"/>
|
||||
</shape>
|
||||
@@ -12,7 +12,6 @@
|
||||
android:layout_height="@dimen/hmi_traffic_light_bg_height"
|
||||
android:layout_marginStart="@dimen/hmi_traffic_light_bg_margin_left"
|
||||
android:layout_marginTop="@dimen/hmi_traffic_light_bg_margin_top"
|
||||
android:background="@drawable/traffic_light_bg"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
/>
|
||||
@@ -41,7 +40,6 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="自车感知"
|
||||
android:textColor="@color/color_FFFFFF"
|
||||
android:textSize="@dimen/hmi_traffic_light_source_size"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
@@ -53,7 +51,6 @@
|
||||
android:id="@+id/hmi_traffic_light_divider"
|
||||
android:layout_width="@dimen/dp_1"
|
||||
android:layout_height="@dimen/dp_47"
|
||||
android:background="@color/color_FFFFFF"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/hmi_traffic_light_source"
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="804dp"
|
||||
android:layout_height="160dp"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#53000000"
|
||||
app:roundLayoutRadius="24dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginStart="30dp"
|
||||
android:layout_marginEnd="30dp"
|
||||
android:layout_marginTop="7dp"
|
||||
android:layout_marginBottom="7dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivOperationDoorImage"
|
||||
android:layout_width="110dp"
|
||||
android:layout_height="110dp"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginTop="25dp"
|
||||
android:layout_marginBottom="25dp"
|
||||
android:layout_marginStart="25dp"
|
||||
android:src="@drawable/v2x_icon_shigu_sanjiaopai"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvOperationDoorTime"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/ivOperationDoorImage"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginEnd="25dp"
|
||||
android:textColor="#80FFFFFF"
|
||||
android:textSize="24dp"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvOperationDoorContent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivOperationDoorImage"
|
||||
app:layout_constraintRight_toRightOf="@id/tvOperationDoorTime"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:layout_marginStart="25dp"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="32dp"
|
||||
android:maxLines="1"
|
||||
android:ellipsize="end"
|
||||
/>
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="804dp"
|
||||
android:layout_height="160dp"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_804"
|
||||
android:layout_height="@dimen/dp_160"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="@drawable/bg_msg_box_v2x"
|
||||
android:layout_gravity="center_horizontal"
|
||||
@@ -57,4 +57,4 @@
|
||||
android:ellipsize="end"
|
||||
/>
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,51 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="804dp"
|
||||
android:layout_height="160dp"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#53000000"
|
||||
app:roundLayoutRadius="24dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
android:layout_marginTop="7dp"
|
||||
android:layout_marginBottom="7dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivOperationDoorImage"
|
||||
android:layout_width="110dp"
|
||||
android:layout_height="110dp"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginTop="25dp"
|
||||
android:layout_marginBottom="25dp"
|
||||
android:layout_marginStart="25dp"
|
||||
android:src="@drawable/v2x_icon_shigu_sanjiaopai"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvOperationDoorTime"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/ivOperationDoorImage"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:layout_marginEnd="25dp"
|
||||
android:textColor="#80FFFFFF"
|
||||
android:textSize="24dp"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvOperationDoorContent"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivOperationDoorImage"
|
||||
app:layout_constraintRight_toRightOf="@id/tvOperationDoorTime"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:layout_marginStart="25dp"
|
||||
android:textColor="#FFFFFFFF"
|
||||
android:textSize="32dp"
|
||||
android:maxLines="1"
|
||||
android:ellipsize="end"
|
||||
/>
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="804dp"
|
||||
android:layout_height="160dp"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
@@ -49,4 +49,4 @@
|
||||
android:text="靠边停车"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
@@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundCanClickConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/clV2XLayout"
|
||||
android:layout_width="@dimen/dp_804"
|
||||
android:layout_height="160dp"
|
||||
android:layout_height="@dimen/dp_160"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="@drawable/bg_msg_box_v2x"
|
||||
android:layout_gravity="center_horizontal"
|
||||
@@ -57,4 +57,4 @@
|
||||
android:ellipsize="end"
|
||||
/>
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundCanClickConstraintLayout>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -8,7 +8,7 @@
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/icon_drag"
|
||||
android:src="@drawable/icon_acceleration_drag"
|
||||
android:padding="15dp"
|
||||
android:layout_gravity="center_horizontal"
|
||||
/>
|
||||
|
||||
@@ -178,6 +178,35 @@
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/badCaseLayout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_216"
|
||||
app:layout_constraintTop_toTopOf="@id/managerLayout"
|
||||
app:layout_constraintBottom_toBottomOf="@id/managerLayout"
|
||||
app:layout_constraintLeft_toRightOf="@id/managerLayout"
|
||||
android:layout_marginStart="142dp"
|
||||
>
|
||||
|
||||
<ImageView
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="150dp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:background="@drawable/debug_icon_bad_case"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="42dp"
|
||||
android:text="@string/debug_bad_case_report"
|
||||
android:textColor="@color/color_FFA7B6F0"
|
||||
android:textSize="32dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_check_title"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -271,8 +300,8 @@
|
||||
android:textColor="@android:color/white"
|
||||
android:textSize="42dp"
|
||||
android:layout_marginLeft="50dp"
|
||||
app:layout_constraintTop_toTopOf="@id/etInputSpeed"
|
||||
app:layout_constraintBottom_toBottomOf="@id/etInputSpeed"
|
||||
app:layout_constraintTop_toTopOf="@id/ivSpeedAdd"
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivSpeedAdd"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvUnit"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
@@ -278,30 +278,6 @@
|
||||
android:textOn="关闭感知优化模式"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbDrawAiCloudFusion"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/dp_10"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:background="@drawable/radio_button_normal_background_right"
|
||||
android:textColor="#000"
|
||||
android:textOff="开启云端感知绘制"
|
||||
android:textOn="关闭云端感知绘制"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbDrawRomaMode"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/dp_10"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:background="@drawable/radio_button_normal_background_right"
|
||||
android:textColor="#000"
|
||||
android:textOff="开启漫游模式"
|
||||
android:textOn="关闭漫游模式"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbObuWarningFusionUnion"
|
||||
android:layout_width="match_parent"
|
||||
@@ -314,6 +290,7 @@
|
||||
android:textOn="关闭obu预警融合"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<!-- 蘑方控制 start -->
|
||||
<ToggleButton
|
||||
android:id="@+id/tbMojie"
|
||||
android:layout_width="match_parent"
|
||||
@@ -336,8 +313,41 @@
|
||||
android:visibility="gone"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:scaleY="1"
|
||||
android:scaleX="1"
|
||||
/>
|
||||
android:scaleX="1" />
|
||||
<!-- 蘑方控制 end -->
|
||||
|
||||
<!-- APP升级数据 start -->
|
||||
<ToggleButton
|
||||
android:id="@+id/tbAppUpgrade"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/dp_10"
|
||||
android:background="@drawable/radio_button_normal_background_right"
|
||||
android:drawableEnd="@drawable/icon_right"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:textOff="APP升级信息"
|
||||
android:textOn="APP升级信息"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvAppHost"
|
||||
style="@style/DebugSettingText"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="gone"
|
||||
android:text="域名: " />
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#F0F0F0" />
|
||||
<TextView
|
||||
android:id="@+id/tvAppContent"
|
||||
style="@style/DebugSettingText"
|
||||
android:visibility="gone"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:minLines="5" />
|
||||
<!-- APP升级数据 end -->
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnIpcReboot"
|
||||
@@ -1092,7 +1102,7 @@
|
||||
app:layout_constraintTop_toTopOf="@id/btnSetObuIP" />
|
||||
|
||||
<View
|
||||
android:id="@+id/obuDivider"
|
||||
android:id="@+id/obuEditDivider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#F0F0F0"
|
||||
@@ -1109,6 +1119,46 @@
|
||||
<!-- android:textSize="@dimen/dp_24"-->
|
||||
<!-- app:layout_constraintTop_toBottomOf="@id/obuDivider" />-->
|
||||
|
||||
<TextView
|
||||
android:id="@+id/obuSendFrequencyTv"
|
||||
style="@style/DebugSettingText"
|
||||
android:text="OBU发送频率设置(默认100ms):"
|
||||
app:layout_constraintTop_toBottomOf="@id/obuEditDivider"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:ignore="MissingConstraints" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnSetFifty"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:text="50ms"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintTop_toBottomOf="@id/obuEditDivider"
|
||||
app:layout_constraintLeft_toRightOf="@+id/obuSendFrequencyTv" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnSetOneHundred"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:text="100ms"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintLeft_toRightOf="@+id/btnSetFifty"
|
||||
app:layout_constraintTop_toBottomOf="@id/obuEditDivider" />
|
||||
|
||||
<View
|
||||
android:id="@+id/obuDivider"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:background="#F0F0F0"
|
||||
app:layout_constraintTop_toBottomOf="@id/btnSetFifty" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/obuStatusCenterLayout"
|
||||
android:layout_width="match_parent"
|
||||
@@ -1296,6 +1346,19 @@
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintTop_toBottomOf="@id/btnConnectServerIp" />
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbStartAutopilotCommand"
|
||||
style="@style/DebugSettingText"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
android:layout_gravity="end"
|
||||
android:layout_marginRight="@dimen/dp_20"
|
||||
app:switchMinWidth="60dp"
|
||||
android:text="后台未发布轨迹不可启动自驾"
|
||||
android:textSize="@dimen/dp_28"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbReportWarning" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<ToggleButton
|
||||
@@ -1306,8 +1369,8 @@
|
||||
android:background="@drawable/setting_toggle_button_background"
|
||||
android:drawableEnd="@drawable/icon_right"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:textOff="HMI控制"
|
||||
android:textOn="HMI控制"
|
||||
android:textOff="打开HMI控制"
|
||||
android:textOn="关闭HMI控制"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<GridLayout
|
||||
@@ -1318,6 +1381,20 @@
|
||||
android:visibility="gone"
|
||||
tools:visibility="visible">
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbControlPassengerDriverMonitor"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_columnWeight="1"
|
||||
android:layout_margin="2dp"
|
||||
android:gravity="center"
|
||||
android:textOff="开启乘客屏直播监控"
|
||||
android:textOn="关闭乘客屏直播监控"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintLeft_toRightOf="@+id/tbChangeCurrentCarIcon"
|
||||
app:layout_constraintTop_toTopOf="@id/tbChangeCurrentCarIcon" />
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbChangeCurrentSkinMode"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -1483,6 +1560,21 @@
|
||||
app:layout_constraintRight_toRightOf="@id/changesight_cross_btn"
|
||||
app:layout_constraintTop_toBottomOf="@id/changesight_cross_btn" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btn_cache_hd_map"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="2dp"
|
||||
android:gravity="center"
|
||||
android:text="缓存高精离线地图"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintLeft_toRightOf="@id/reset_changesight"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/changesight_far_btn"
|
||||
android:visibility="gone"
|
||||
/>
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbChangeCurrentCarIcon"
|
||||
android:layout_width="0dp"
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/rclContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:roundLayoutRadius="24dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivNormal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
|
||||
<!--摄像头数据需要两种播放方式-->
|
||||
<TextureView
|
||||
android:id="@+id/textureViewDriverMonitor"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/liveProgressBar"
|
||||
android:layout_width="90dp"
|
||||
android:layout_height="90dp"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateBehavior="repeat"
|
||||
android:indeterminateDuration="2000"
|
||||
android:indeterminateDrawable="@anim/progressbar_drawable"
|
||||
android:indeterminateOnly="true"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvLoadingHit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="加载中……"
|
||||
android:textColor="#2D3E5F"
|
||||
android:textSize="28dp"
|
||||
app:layout_constraintEnd_toEndOf="@+id/liveProgressBar"
|
||||
app:layout_constraintStart_toStartOf="@+id/liveProgressBar"
|
||||
app:layout_constraintTop_toBottomOf="@+id/liveProgressBar" />
|
||||
|
||||
</com.mogo.eagle.core.widget.RoundConstraintLayout>
|
||||
@@ -0,0 +1,23 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/ll_roma_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/roma_bg_selector"
|
||||
android:elevation="@dimen/dp_10"
|
||||
>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivRomaView"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
android:layout_gravity="center"
|
||||
android:background="@drawable/romafront_select_bg"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="@dimen/dp_121"
|
||||
android:layout_height="@dimen/dp_121"
|
||||
tools:ignore="MissingDefaultResource">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,39 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/cl_roma_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_roma_bg"
|
||||
android:layout_width="@dimen/dp_102"
|
||||
android:layout_height="@dimen/dp_102"
|
||||
android:layout_margin="40dp"
|
||||
android:background="@drawable/roma_bg_selector"
|
||||
android:elevation="@dimen/dp_10"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivRomaView"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:src="@drawable/romafront_select_bg"
|
||||
android:elevation="@dimen/dp_10"
|
||||
/>
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -191,6 +191,34 @@
|
||||
app:layout_constraintRight_toLeftOf="@id/verticalGuideLine"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbGreenWaveSop"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="绿波通行"
|
||||
android:paddingTop="25dp"
|
||||
android:paddingBottom="25dp"
|
||||
android:scaleY="1.2"
|
||||
android:scaleX="1.2"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbCloudWeaknessTrafficSop"
|
||||
app:layout_constraintLeft_toRightOf="@id/verticalGuideLine"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbRunRedLightSop"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="闯红灯预警"
|
||||
android:paddingTop="25dp"
|
||||
android:paddingBottom="25dp"
|
||||
android:scaleY="1.2"
|
||||
android:scaleX="1.2"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbCloudWeaknessTrafficSop"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/verticalGuideLine"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbIPCReport"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -200,17 +228,45 @@
|
||||
android:paddingBottom="25dp"
|
||||
android:scaleY="1.2"
|
||||
android:scaleX="1.2"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbObuWeaknessTrafficSop"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbGreenWaveSop"
|
||||
app:layout_constraintRight_toLeftOf="@id/verticalGuideLine"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbV2nPnc"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="V2N场景进PNC"
|
||||
android:paddingTop="25dp"
|
||||
android:paddingBottom="25dp"
|
||||
android:scaleY="1.2"
|
||||
android:scaleX="1.2"
|
||||
app:layout_constraintLeft_toRightOf="@id/verticalGuideLine"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbGreenWaveSop"
|
||||
/>
|
||||
|
||||
<androidx.appcompat.widget.SwitchCompat
|
||||
android:id="@+id/tbNewV2NData"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="V2N新链路"
|
||||
android:paddingTop="25dp"
|
||||
android:paddingBottom="25dp"
|
||||
android:scaleY="1.2"
|
||||
android:scaleX="1.2"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbIPCReport"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@id/verticalGuideLine"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvSpeedThresholdTitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbIPCReport"
|
||||
app:layout_constraintTop_toBottomOf="@id/tbNewV2NData"
|
||||
android:text="变道速度阈值:"
|
||||
android:textSize="@dimen/dp_36"
|
||||
android:textColor="#1A1A1A"
|
||||
|
||||
@@ -10,10 +10,8 @@
|
||||
android:layout_width="150dp"
|
||||
android:layout_height="150dp"
|
||||
android:layout_marginStart="113dp"
|
||||
android:src="@drawable/icon_pad"
|
||||
android:src="@drawable/icon_version_pad"
|
||||
android:layout_marginTop="40dp"
|
||||
android:background="@drawable/version_latest_background"
|
||||
android:padding="12dp"
|
||||
android:clickable="true"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
@@ -63,9 +61,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivPadVersion"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:layout_marginStart="405dp"
|
||||
android:src="@drawable/icon_ad"
|
||||
android:padding="12dp"
|
||||
android:background="@drawable/version_latest_background"
|
||||
android:src="@drawable/icon_version_ad_normal"
|
||||
/>
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.widget.CircularProgressView
|
||||
@@ -107,10 +103,10 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvAdVersionContent"
|
||||
android:layout_width="250dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/ivAdVersion"
|
||||
app:layout_constraintRight_toRightOf="@id/ivAdVersion"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvAdVersionTitle"
|
||||
app:layout_constraintRight_toRightOf="@id/tvAdVersionTitle"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvAdVersionTitle"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:textColor="#FFA7B6F0"
|
||||
@@ -127,9 +123,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivAdVersion"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:layout_marginStart="680dp"
|
||||
android:src="@drawable/icon_hd_map"
|
||||
android:padding="12dp"
|
||||
android:background="@drawable/version_latest_background"
|
||||
android:src="@drawable/icon_version_hd_map"
|
||||
/>
|
||||
|
||||
<ImageView
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:visibility="gone">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_wu1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:alpha="0"
|
||||
android:src="@drawable/wu1"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_wu2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:alpha="0"
|
||||
android:src="@drawable/wu2"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -84,4 +84,14 @@
|
||||
<attr name="bgDrawable" format="reference"/>
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="RomaPassengerView">
|
||||
<attr name="roma_open" format="reference"/>
|
||||
<attr name="roma_close" format="reference"/>
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="RomaView">
|
||||
<attr name="roma_open_bg" format="reference"/>
|
||||
<attr name="roma_close_bg" format="reference"/>
|
||||
</declare-styleable>
|
||||
|
||||
</resources>
|
||||
@@ -21,6 +21,7 @@
|
||||
<color name="color_0099dd">#0099dd</color>
|
||||
<color name="color_FFFFFF">#FFFFFF</color>
|
||||
<color name="color_2C2E30">#2C2E30</color>
|
||||
<color name="color_2D3E5F">#2D3E5F</color>
|
||||
<color name="color_D4D8DC">#D4D8DC</color>
|
||||
<color name="color_27FFFFFF">#27FFFFFF</color>
|
||||
<color name="color_1E111111">#1E111111</color>
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
<dimen name="dp_18">18dp</dimen>
|
||||
<dimen name="dp_30">30dp</dimen>
|
||||
<dimen name="dp_34">34dp</dimen>
|
||||
<dimen name="dp_34_5">34.5dp</dimen>
|
||||
<dimen name="dp_36">36dp</dimen>
|
||||
<dimen name="dp_38">38dp</dimen>
|
||||
<dimen name="dp_42">42dp</dimen>
|
||||
@@ -63,7 +64,7 @@
|
||||
<dimen name="hmi_traffic_light_bg_margin_left">15dp</dimen>
|
||||
<dimen name="hmi_traffic_light_bg_margin_top">17dp</dimen>
|
||||
<dimen name="hmi_traffic_light_icon_size">154dp</dimen>
|
||||
<dimen name="hmi_traffic_light_time_view_width">71dp</dimen>
|
||||
<dimen name="hmi_traffic_light_time_view_width">110dp</dimen>
|
||||
<dimen name="hmi_traffic_light_time_size">60dp</dimen>
|
||||
<dimen name="hmi_traffic_light_source_size">32dp</dimen>
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
<string name="debug_panel_fb">录包设置</string>
|
||||
<string name="debug_sop">运营面板</string>
|
||||
<string name="debug_bad_case_manager">录包管理</string>
|
||||
<string name="debug_bad_case_report">上报</string>
|
||||
<string name="check_vehicle_speed_setting">车速设置</string>
|
||||
<string name="bus_operation_title">账户信息</string>
|
||||
<string name="check_system_operation">系统运行</string>
|
||||
@@ -78,4 +79,5 @@
|
||||
<string name="location_try_again">请检查定位是否正常</string>
|
||||
<string name="ok_tip">确定</string>
|
||||
<string name="retry">重试</string>
|
||||
<string name="hint_exit_app_again">再按一次退出应用</string>
|
||||
</resources>
|
||||
|
||||