Merge branch 'master' of https://gitlab.navinfo.com/CollectVehicle/OneMapQS
Conflicts: app/src/main/java/com/navinfo/omqs/ui/activity/map/MainViewModel.kt vtm
This commit is contained in:
@@ -72,13 +72,13 @@ enum class DataCodeEnum(var tableName: String, var code: String) {
|
||||
OMDB_LANE_LINK_LG("车道中心线", "5001");
|
||||
|
||||
companion object {
|
||||
fun findTableNameByCode(code: String): String? {
|
||||
fun findTableNameByCode(code: String): String {
|
||||
for (enumInstance in DataCodeEnum.values()) {
|
||||
if (enumInstance.code == code) {
|
||||
return enumInstance.tableName
|
||||
}
|
||||
}
|
||||
return null // 若未找到匹配的 code,则返回 null 或其他适当的默认值
|
||||
return "" // 若未找到匹配的 code,则返回 null 或其他适当的默认值
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -345,6 +345,16 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
}
|
||||
}
|
||||
|
||||
fun removeMarker() {
|
||||
for (e in mDefaultMarkerLayer.itemList) {
|
||||
if (e is MarkerItem) {
|
||||
mDefaultMarkerLayer.removeItem(e)
|
||||
break
|
||||
}
|
||||
}
|
||||
mMapView.vtmMap.updateMap(true)
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 增加或更新marker
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
package com.navinfo.collect.library.utils
|
||||
|
||||
import android.content.Context
|
||||
import java.io.InputStream
|
||||
|
||||
class AssetsFileLoadUtil {
|
||||
companion object {
|
||||
fun loadWarningSvg(context: Context, code: String): InputStream? {
|
||||
return context.assets.open("omdb/appendix/1105_${code}_0.svg")
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user