修改数据上传
This commit is contained in:
parent
611385c145
commit
d3fd50f941
@ -17,8 +17,9 @@ class LayerConfigUtils {
|
||||
fun getLayerConfigList(): List<ImportConfig> {
|
||||
// 首先读取Shared文件,如果存在则直接返回,否则读取config文件
|
||||
return SPStaticUtils.getString(Constant.EVENT_LAYER_MANAGER_CHANGE, null).let {
|
||||
if (this!=null) {
|
||||
val result: List<ImportConfig> = gson.fromJson(it, object : TypeToken<List<ImportConfig>>(){}.type)
|
||||
if (it != null) {
|
||||
val result: List<ImportConfig> =
|
||||
gson.fromJson(it, object : TypeToken<List<ImportConfig>>() {}.type)
|
||||
result
|
||||
} else {
|
||||
LayerConfigUtils.getLayerConfigListFromAssetsFile()
|
||||
@ -35,7 +36,8 @@ class LayerConfigUtils {
|
||||
}
|
||||
if (otherConfigFile.exists()) {
|
||||
val otherConfiStr = FileIOUtils.readFile2String(otherConfigFile)
|
||||
val otherConfig = gson.fromJson<ImportConfig>(otherConfiStr, ImportConfig::class.java)
|
||||
val otherConfig =
|
||||
gson.fromJson<ImportConfig>(otherConfiStr, ImportConfig::class.java)
|
||||
resultList.add(otherConfig)
|
||||
}
|
||||
return resultList
|
||||
|
@ -171,6 +171,7 @@ class EvaluationResultViewModel @Inject constructor(
|
||||
it.linkId =
|
||||
linkList[0].properties[LinkTable.linkPid] ?: ""
|
||||
mapController.lineHandler.showLine(linkList[0].geometry)
|
||||
Log.e("jingo", "捕捉到的linkId = ${it.linkId}")
|
||||
} else {
|
||||
it.linkId = ""
|
||||
mapController.lineHandler.removeLine()
|
||||
@ -424,7 +425,8 @@ class EvaluationResultViewModel @Inject constructor(
|
||||
pop!!.width = ViewGroup.LayoutParams.MATCH_PARENT
|
||||
pop!!.height = ViewGroup.LayoutParams.WRAP_CONTENT
|
||||
pop!!.setBackgroundDrawable(BitmapDrawable())
|
||||
val view = View.inflate(activity as Context, R.layout.cv_card_voice_rcd_hint_window, null)
|
||||
val view =
|
||||
View.inflate(activity as Context, R.layout.cv_card_voice_rcd_hint_window, null)
|
||||
pop!!.contentView = view
|
||||
volume = view.findViewById(R.id.volume)
|
||||
}
|
||||
|
@ -39,6 +39,9 @@ class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(
|
||||
//绘制线 样式
|
||||
private val lineStyle: Style
|
||||
|
||||
//高亮线绘制线 样式
|
||||
private val defaultLineStyle: Style
|
||||
|
||||
//线型编辑时的样式
|
||||
private val editTempStyle: Style
|
||||
|
||||
@ -60,14 +63,16 @@ class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(
|
||||
private val mDefaultPathLayer: PathLayer
|
||||
|
||||
val omdbTaskLinkLayer by lazy {
|
||||
val omdbTaskLinkLayer = OmdbTaskLinkLayer(mMapView.vtmMap,
|
||||
val omdbTaskLinkLayer = OmdbTaskLinkLayer(
|
||||
mMapView.vtmMap,
|
||||
Style.builder()
|
||||
// .stippleColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.strokeWidth(4f)
|
||||
.fixed(true).build())
|
||||
.fixed(true).build()
|
||||
)
|
||||
addLayer(omdbTaskLinkLayer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
omdbTaskLinkLayer
|
||||
}
|
||||
@ -84,6 +89,15 @@ class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fixed(true).build()
|
||||
|
||||
|
||||
defaultLineStyle = Style.builder()
|
||||
.stippleColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.strokeWidth(10f)
|
||||
.fillColor(context.resources.getColor(R.color.teal_200, null))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.teal_200, null))
|
||||
.fixed(true).build()
|
||||
|
||||
newTempStyle =
|
||||
Style.builder().stippleColor(context.resources.getColor(R.color.transparent, null))
|
||||
.stipple(30).stippleWidth(30f).strokeWidth(4f)
|
||||
@ -95,8 +109,8 @@ class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(
|
||||
.stipple(30).stippleWidth(30f).strokeWidth(8f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.fixed(true).randomOffset(false).build()
|
||||
mDefaultPathLayer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
addLayer(mDefaultPathLayer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
mDefaultPathLayer = PathLayer(mMapView.vtmMap, defaultLineStyle)
|
||||
addLayer(mDefaultPathLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
mPathLayer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
// addLayer(mPathLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user