fix bug of scene
This commit is contained in:
@@ -35,7 +35,7 @@ class SceneManager {
|
||||
private const val NET = "NET"
|
||||
private const val BUS = "BUS"
|
||||
private const val TAXI = "TAXI"
|
||||
private const val TAXI_P = "TAXI-P"
|
||||
private const val TAXI_P = "TAXI_P"
|
||||
private const val OTHER = "OTHER"
|
||||
|
||||
val sceneManager: SceneManager by lazy(LazyThreadSafetyMode.SYNCHRONIZED) {
|
||||
@@ -43,7 +43,6 @@ class SceneManager {
|
||||
}
|
||||
}
|
||||
|
||||
private var sceneCache: MutableMap<String, SceneLogCache> = scene.getSceneCache()
|
||||
private var sceneModuleTAG: SceneModuleTAG = SceneModuleTAG(mutableMapOf())
|
||||
private var sceneLogTAG: SceneLogTAG = SceneLogTAG(mutableMapOf())
|
||||
|
||||
@@ -74,6 +73,7 @@ class SceneManager {
|
||||
}
|
||||
|
||||
fun updateModuleTAG(moduleTag: MutableMap<String, SceneModule>) {
|
||||
val sceneCache = scene.getSceneCache()
|
||||
moduleTag.iterator().forEach { map ->
|
||||
val name = map.value.name
|
||||
val logger = map.value.log
|
||||
@@ -96,6 +96,7 @@ class SceneManager {
|
||||
}
|
||||
|
||||
private fun updateSceneModuleTAG() {
|
||||
val sceneCache = scene.getSceneCache()
|
||||
sceneModuleTAG.map.iterator().forEach { map ->
|
||||
val sceneModule = map.value
|
||||
val sceneLogCache = sceneCache[sceneModule.name]
|
||||
@@ -109,6 +110,7 @@ class SceneManager {
|
||||
}
|
||||
|
||||
private fun realUpdateSceneTAG(name: String, logger: Boolean) {
|
||||
val sceneCache = scene.getSceneCache()
|
||||
when (name) {
|
||||
TAXI -> {
|
||||
sceneCache[M_TAXI]?.logger = logger
|
||||
|
||||
Reference in New Issue
Block a user