fix bug of instance
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
package com.mogo.eagle.core.function.v2x.trafficlight
|
||||
|
||||
import android.content.Context
|
||||
import com.mogo.eagle.core.data.trafficlight.*
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
|
||||
|
||||
@@ -14,13 +13,8 @@ class TrafficLightHMIManager {
|
||||
}
|
||||
}
|
||||
|
||||
private var mContext: Context? = null
|
||||
private var initView: Boolean = false
|
||||
|
||||
fun init(context: Context) {
|
||||
mContext = context
|
||||
}
|
||||
|
||||
fun updateTrafficLight(trafficLightResult: TrafficLightResult) {
|
||||
val currentTrafficLight = trafficLightResult.currentRoadTrafficLight()
|
||||
currentTrafficLight?.let {
|
||||
@@ -56,6 +50,7 @@ class TrafficLightHMIManager {
|
||||
}
|
||||
|
||||
fun hideTrafficLight() {
|
||||
initView = false
|
||||
CallerHmiManager.disableWarningTrafficLight()
|
||||
}
|
||||
}
|
||||
@@ -21,7 +21,6 @@ class TrafficLightProvider : ITrafficLightProvider {
|
||||
|
||||
override fun initTrafficLightServer(context: Context) {
|
||||
MogoTrafficLightManager.INSTANCE.initServer(context)
|
||||
TrafficLightHMIManager.INSTANCE.init(context)
|
||||
}
|
||||
|
||||
override fun getTrafficLightCurrentState(): TrafficLightDetail? {
|
||||
|
||||
Reference in New Issue
Block a user