From b636f1f6f5a3997cdde70f7db23661fb64b77b07 Mon Sep 17 00:00:00 2001 From: xuxinchao Date: Fri, 20 Sep 2024 18:23:12 +0800 Subject: [PATCH] =?UTF-8?q?[6.7.0]Tab=E6=B6=88=E6=81=AF=E7=9B=92=E5=AD=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/function/hmi/bone/BoneTabLayout.kt | 4 +- ...{MsgBoxListTabView.kt => MsgBoxTabView.kt} | 6 +- .../main/res/layout/layout_msg_box_tab.xml | 81 +++++++++++++++++++ .../src/main/res/layout/view_bone_tab.xml | 11 +++ 4 files changed, 98 insertions(+), 4 deletions(-) rename core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/{MsgBoxListTabView.kt => MsgBoxTabView.kt} (98%) create mode 100644 core/function-impl/mogo-core-function-hmi/src/main/res/layout/layout_msg_box_tab.xml diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/BoneTabLayout.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/BoneTabLayout.kt index 86ce78be1c..85667786fe 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/BoneTabLayout.kt +++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/BoneTabLayout.kt @@ -10,6 +10,7 @@ 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.scene.SceneConstant.Companion.M_HMI import kotlinx.android.synthetic.main.view_bone_tab.view.carInfoTabView +import kotlinx.android.synthetic.main.view_bone_tab.view.msgBoxTabView import kotlinx.android.synthetic.main.view_bone_tab.view.tabSwitchCarInfo import kotlinx.android.synthetic.main.view_bone_tab.view.tabSwitchMore import kotlinx.android.synthetic.main.view_bone_tab.view.tabSwitchMsgBox @@ -114,8 +115,9 @@ class BoneTabLayout @JvmOverloads constructor( tabSwitchMsgBox.switchTab(check) if (check) { tabSwitchMsgBox.updateNotice(false) + msgBoxTabView.visibility = VISIBLE } else { - + msgBoxTabView.visibility = GONE } } diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxListTabView.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxTabView.kt similarity index 98% rename from core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxListTabView.kt rename to core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxTabView.kt index cc1f7510e0..fdbcc2a63e 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxListTabView.kt +++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/bone/tab/MsgBoxTabView.kt @@ -32,7 +32,7 @@ import org.greenrobot.eventbus.ThreadMode * @description 司机端消息盒子打开列表视图 * @since: 2022/11/25 */ -class MsgBoxListTabView @JvmOverloads constructor( +class MsgBoxTabView @JvmOverloads constructor( context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0 @@ -40,10 +40,10 @@ class MsgBoxListTabView @JvmOverloads constructor( IOrderListener { init { - LayoutInflater.from(context).inflate(R.layout.layout_driver_msg_box_list, this, true) + LayoutInflater.from(context).inflate(R.layout.layout_msg_box_tab, this, true) initView() } - private val TAG = "DriverMsgBoxListView" + private val TAG = "MsgBoxTabView" private var noticeList: ArrayList ?= null //通知消息列表 private var fmList: ArrayList ?= ArrayList() //FM信息消息列表 private var ipcReportList: ArrayList ?= null //车辆系统信息消息列表 diff --git a/core/function-impl/mogo-core-function-hmi/src/main/res/layout/layout_msg_box_tab.xml b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/layout_msg_box_tab.xml new file mode 100644 index 0000000000..39a207eca3 --- /dev/null +++ b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/layout_msg_box_tab.xml @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_bone_tab.xml b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_bone_tab.xml index a188b8280a..ea6b300b70 100644 --- a/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_bone_tab.xml +++ b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_bone_tab.xml @@ -22,6 +22,17 @@ app:layout_constraintRight_toRightOf="parent" app:layout_constraintTop_toTopOf="parent" /> + +