[6.7.0] fix bug
This commit is contained in:
@@ -5,6 +5,7 @@ import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.enums.Carmodel
|
||||
import com.mogo.eagle.core.function.api.och.IOchFunctionCall
|
||||
import com.mogo.eagle.core.function.call.och.CallerOchFunctionCallManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
@@ -40,12 +41,8 @@ class BoneContainerView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
private fun initView() {
|
||||
clBoneTab.loginOut { //todo 判断没有logout caller出去
|
||||
if(logOut != null){
|
||||
logOut?.invoke()
|
||||
}else{
|
||||
|
||||
}
|
||||
clBoneTab.loginOut {
|
||||
CallerOchFunctionCallManager.invokeLoginOut()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -57,7 +54,7 @@ class BoneContainerView @JvmOverloads constructor(
|
||||
this.logOut = logOut
|
||||
}
|
||||
|
||||
override fun invokeCarMode(carModel: String?) {
|
||||
override fun invokeCarMode(carModel: Carmodel?) {
|
||||
super.invokeCarMode(carModel)
|
||||
clBoneTab.setCarMode(carModel)
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.enums.Carmodel
|
||||
import com.mogo.eagle.core.function.api.datacenter.msgbox.IMsgBoxEventListener
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxEventListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
@@ -92,7 +93,7 @@ class BoneTabLayout @JvmOverloads constructor(
|
||||
carInfoTabView.setLoginInfo(loginNo)
|
||||
}
|
||||
|
||||
fun setCarMode(carModel: String?) {
|
||||
fun setCarMode(carModel: Carmodel?) {
|
||||
carInfoTabView.setCarMode(carModel)
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.commons.storage.SharedPrefsMgr
|
||||
import com.mogo.eagle.core.data.app.AppConfigInfo
|
||||
import com.mogo.eagle.core.data.enums.Carmodel
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotCarConfigListener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsListener
|
||||
@@ -168,19 +169,13 @@ class CarInfoTabView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
fun setCarMode(carModel:String?){
|
||||
fun setCarMode(carModel: Carmodel?){
|
||||
UiThreadHandler.post {
|
||||
if(carModel.isNullOrEmpty()){
|
||||
if(carModel == null){
|
||||
ivCarType.visibility = GONE
|
||||
}else{
|
||||
ivCarType.visibility = VISIBLE
|
||||
when(carModel){
|
||||
"b1" -> ivCarType.setImageResource(R.drawable.icon_car_b1)
|
||||
"b2" -> ivCarType.setImageResource(R.drawable.icon_car_b2)
|
||||
"t1" -> ivCarType.setImageResource(R.drawable.icon_car_t1)
|
||||
"t2" -> ivCarType.setImageResource(R.drawable.icon_car_t2)
|
||||
"m1" -> ivCarType.setImageResource(R.drawable.icon_car_m1)
|
||||
}
|
||||
ivCarType.setImageResource(carModel.resId)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user