fix: 合并代码
@@ -79,7 +79,7 @@ dependencies {
|
||||
implementation "net.sf.kxml:kxml2:2.3.0"
|
||||
implementation 'org.slf4j:slf4j-api:2.0.7'
|
||||
implementation project(":vtm-themes")
|
||||
api project(":vtm-android")
|
||||
implementation project(":vtm-android")
|
||||
implementation project(':vtm-extras')
|
||||
implementation project(":vtm-http")
|
||||
// implementation "org.mapsforge:vtm-themes:$vtmVersion"
|
||||
|
||||
@@ -1479,132 +1479,20 @@
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!-- <!– 自定义渲染样式 –>-->
|
||||
<!-- <m k="navi_type" zoom-max="22" zoom-min="15">-->
|
||||
<!-- <!– 车道中心线 –>-->
|
||||
<!-- <m v="had_lane_link">-->
|
||||
<!-- <line dasharray="20,20" fix="true" stipple-stroke="#00000000" stroke="#ff0000"-->
|
||||
<!-- width="0.3" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!– 车道边线 –>-->
|
||||
<!-- <m v="had_lane_mark_link">-->
|
||||
<!-- <line stipple-width="0.5" stroke="#0000ff" width="0.1" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–道路箭头 objectArrow–>-->
|
||||
<!-- <m v="object_arrow">-->
|
||||
<!-- <area fade="5" fill="#88aaaa00" stroke="#ff0000" stroke-width="0.1"></area>-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–人行横道 objectcrosswalk–>-->
|
||||
<!-- <m v="object_crosswalk">-->
|
||||
<!-- <area fill="#88800080" stroke="#ff0000" stroke-width="0.2"></area>-->
|
||||
<!-- <caption style="bold" dy="12" fill="#4D2F08" k="name" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="2.0" />-->
|
||||
<!-- <caption style="bold" dy="-12" fill="#4D2F08" k="ele" size="12" stroke="#ffffff"-->
|
||||
<!-- stroke-width="2.0" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–杆状物 objectpole–>-->
|
||||
<!-- <m v="object_pole">-->
|
||||
<!-- <line stipple-width="0.5" stroke="#8800aaaa" width="0.1" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–对象标志 objectsymbol–>-->
|
||||
<!-- <m v="object_symbol">-->
|
||||
<!-- <area fill="#880000cc" stroke="#0000cc" stroke-width="0.2"></area>-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–交通信号灯 objectTrfficLights–>-->
|
||||
<!-- <m v="object_trrfic">-->
|
||||
<!-- <area fill="#8800cc00" stroke="#00cc00" stroke-width="0.2"></area>-->
|
||||
<!-- </m>-->
|
||||
|
||||
<!-- <m zoom-max="19" zoom-min="15">-->
|
||||
<!-- <text use="ferry" />-->
|
||||
<!-- </m>-->
|
||||
|
||||
<!-- <!–道路方向–>-->
|
||||
<!-- <m v="symbol_object_arrow">-->
|
||||
<!-- <symbol use="oneway"></symbol>-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–杆状物–>-->
|
||||
<!-- <m v="symbol_object_pole">-->
|
||||
<!-- <symbol src="assets:symbols/gondola.svg" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–对象标志–>-->
|
||||
<!-- <m v="symbol_object_symbol">-->
|
||||
<!-- <symbol src="assets:symbols/peak.svg" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!–交通信号灯–>-->
|
||||
<!-- <m v="symbol_object_traffic">-->
|
||||
<!-- <symbol src="assets:symbols/traffic_signal.svg" />-->
|
||||
<!-- </m>-->
|
||||
<!-- </m>-->
|
||||
|
||||
<!-- <m k="nav_style">-->
|
||||
<!-- <m v="symbol_object_line">-->
|
||||
<!-- <m k="rule" zoom-max="22" zoom-min="15">-->
|
||||
<!-- <!– 蓝色黑色间隔线 –>-->
|
||||
<!-- <m v="blue_link">-->
|
||||
<!-- <line dasharray="20,20" fix="true" stipple-stroke="#00000000" stroke="#00000000"-->
|
||||
<!-- width="0.1" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <!– 黄色线 –>-->
|
||||
<!-- <m v="yellow_link">-->
|
||||
<!-- <line stipple-width="0.1" stroke="#f4ea2a" width="0.1" />-->
|
||||
<!-- </m>-->
|
||||
<!-- </m>-->
|
||||
<!-- <line stipple-width="0.5" stroke="#33aaaa" width="0.3" />-->
|
||||
<!-- </m>-->
|
||||
<!-- <m v="symbol_track_point" zoom-max="25" zoom-min="10">-->
|
||||
<!-- <symbol src="assets:symbols/dot_blue.svg" />-->
|
||||
<!-- </m>-->
|
||||
<!-- </m>-->
|
||||
|
||||
<m k="qi_table">
|
||||
<!--车道数-->
|
||||
<m v="OMDB_LANE_NUM">
|
||||
<m k="laneNum">
|
||||
<m v="1">
|
||||
<line stroke="#545D6C" width="3" />
|
||||
</m>
|
||||
<m v="2">
|
||||
<line stroke="#545D6C" width="6" />
|
||||
</m>
|
||||
<m v="3">
|
||||
<line stroke="#545D6C" width="9" />
|
||||
</m>
|
||||
<m v="4">
|
||||
<line stroke="#545D6C" width="12" />
|
||||
</m>
|
||||
<m v="5">
|
||||
<line stroke="#545D6C" width="15" />
|
||||
</m>
|
||||
<m v="6">
|
||||
<line stroke="#545D6C" width="18" />
|
||||
</m>
|
||||
<m v="7">
|
||||
<line stroke="#545D6C" width="21" />
|
||||
</m>
|
||||
<m v="8">
|
||||
<line stroke="#545D6C" width="24" />
|
||||
</m>
|
||||
<m v="9">
|
||||
<line stroke="#545D6C" width="27" />
|
||||
</m>
|
||||
<m v="10">
|
||||
<line stroke="#545D6C" width="30" />
|
||||
</m>
|
||||
<m v="11">
|
||||
<line stroke="#545D6C" width="33" />
|
||||
</m>
|
||||
<m v="12">
|
||||
<line stroke="#545D6C" width="36" />
|
||||
</m>
|
||||
</m>
|
||||
</m>
|
||||
<!-- 道路线 -->
|
||||
<m v="OMDB_RD_LINK">
|
||||
<m v="OMDB_RD_LINK" zoom-max="19">
|
||||
<line stroke="#9c9c9c" width="1" />
|
||||
</m>
|
||||
|
||||
<!-- 检查点 -->
|
||||
<m v="OMDB_CHECKPOINT" zoom-max="19">
|
||||
<symbol src="assets:omdb/icon_1012_0.svg" symbol-height="64"
|
||||
symbol-width="64"></symbol>
|
||||
</m>
|
||||
|
||||
<!--道路种别-->
|
||||
<m v="OMDB_RD_LINK_KIND">
|
||||
<m v="OMDB_RD_LINK_KIND" zoom-max="19">
|
||||
<outline-layer id="kind0" stroke="#44000000" width="0.1" />
|
||||
<outline-layer id="kind1" stroke="#aa807040" width="0.1" />
|
||||
<m k="kind" v="1">
|
||||
@@ -1637,159 +1525,170 @@
|
||||
</m>
|
||||
|
||||
<!--常规点限速-->
|
||||
<m v="OMDB_SPEEDLIMIT">
|
||||
<m v="OMDB_SPEEDLIMIT" zoom-max="19">
|
||||
<m k="speedFlag" v="0">
|
||||
<!-- <symbol src="assets:omdb/round_speedlimit.svg" symbol-width="30" symbol-height="30"></symbol>-->
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4002_0.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
<m k="speedFlag" v="1">
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4002_1.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--条件点限速-->
|
||||
<m v="OMDB_SPEEDLIMIT_COND">
|
||||
<m k="speedFlag" v="0">
|
||||
<!-- <symbol src="assets:omdb/round_speedlimit.svg" symbol-width="30" symbol-height="30"></symbol>-->
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4003_0.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
<m k="speedFlag" v="1">
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4003_1.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--可变点限速-->
|
||||
<m v="OMDB_SPEEDLIMIT_VAR">
|
||||
<m v="OMDB_SPEEDLIMIT_VAR" zoom-max="19">
|
||||
<m k="speedFlag" v="0">
|
||||
<!-- <symbol src="assets:omdb/round_speedlimit.svg" symbol-width="30" symbol-height="30"></symbol>-->
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4004_0.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
<m k="speedFlag" v="1">
|
||||
<caption fill="#000000" k="maxSpeed" priority="0" size="12" stroke="#ffffff"
|
||||
stroke-width="1.0"></caption>
|
||||
<symbol src="assets:omdb/icon_4004_1.png" symbol-height="46"
|
||||
<symbol src="assets:omdb/icon_4004_0.svg" symbol-height="46"
|
||||
symbol-width="46"></symbol>
|
||||
<!-- <caption k="minSpeed" dy="-28" fill="#000000" priority="0" size="14" stroke="#ffffff"-->
|
||||
<!-- stroke-width="1.0"></caption>-->
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--车道中心线-->
|
||||
<m v="OMDB_LANE_LINK_LG">
|
||||
<line dasharray="35,35" stroke="#ecf0f1" width="0.1" />
|
||||
<m v="OMDB_LANE_LINK_LG" zoom-min="20">
|
||||
<m k="width" v="~">
|
||||
<line stroke="#7A88A0" width="5" />
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!-- 道路边界类型 -->
|
||||
<m v="OMDB_RDBOUND_BOUNDARYTYPE">
|
||||
<line stroke="#ffffff" width="0.1" />
|
||||
<m v="OMDB_RDBOUND_BOUNDARYTYPE" zoom-min="20">
|
||||
<outline-layer id="boundaryType" stroke="#8e44ad" width="0.1" />
|
||||
<m k="boundaryType" v="0|2|3|4|5|6|7|8|9">
|
||||
<line stroke="#ffffff" use="boundaryType" width="0.1"/>
|
||||
</m>
|
||||
<m k="boundaryType" v="1">
|
||||
<!--无标线无可区分边界-->
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#ffffff" width="0.2"/>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!-- 车道边界类型 -->
|
||||
<m v="OMDB_LANE_MARK_BOUNDARYTYPE">
|
||||
<outline-layer id="boundary" stroke="#ffffff" width="0.2" />
|
||||
<m k="boundaryType">
|
||||
<m v="OMDB_LANE_MARK_BOUNDARYTYPE" zoom-min="20">
|
||||
<outline-layer id="boundary" stroke="#ffffff" width="0.1" />
|
||||
<m k="boundaryType" v="2">
|
||||
<!--标线-->
|
||||
<m v="2">
|
||||
<m k="markType">
|
||||
<m k="markType" v="0|1|4|5|6|7|8">
|
||||
<!--其他|实线-->
|
||||
<m k="markColor" v="1">
|
||||
<line stroke="#ffffff" use="boundaryType" />
|
||||
</m>
|
||||
<m k="markColor" v="2">
|
||||
<line stroke="#eccc68" use="boundaryType" />
|
||||
</m>
|
||||
|
||||
<m k="markColor" v="6">
|
||||
<line stroke="#0000ff" use="boundaryType" />
|
||||
</m>
|
||||
|
||||
<m k="markColor" v="7">
|
||||
<line stroke="#00ff00" use="boundaryType" />
|
||||
</m>
|
||||
|
||||
<m k="markColor" v="0|9">
|
||||
<line stroke="#8e44ad" use="boundaryType" />
|
||||
</m>
|
||||
</m>
|
||||
<m k="markType" v="2|3">
|
||||
<!--其他|实线-->
|
||||
<m v="0|1|2|3|4|5|6|7|8">
|
||||
|
||||
<!--其他|实线-->
|
||||
<m v="0|1">
|
||||
<m k="markColor">
|
||||
<m v="0|1">
|
||||
<line stroke="#ffffff" use="boundaryType" />
|
||||
</m>
|
||||
<m v="2">
|
||||
<line stroke="#eccc68" use="boundaryType" />
|
||||
</m>
|
||||
<m v="6">
|
||||
<line stroke="#0000ff" use="boundaryType" />
|
||||
</m>
|
||||
<m v="7">
|
||||
<line stroke="#00ff00" use="boundaryType" />
|
||||
</m>
|
||||
<m v="9">
|
||||
<line stroke="#8e44ad" use="boundaryType" />
|
||||
</m>
|
||||
</m>
|
||||
<m k="markColor" v="1">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#ffffff" width="0.1"/>
|
||||
</m>
|
||||
<!--虚线-->
|
||||
<m v="2">
|
||||
<m k="markColor">
|
||||
<m v="0|1">
|
||||
<line dasharray="13,135" stipple="5" stipple-stroke="#000000"
|
||||
stroke="#ffffff" use="boundaryType" />
|
||||
</m>
|
||||
<m v="2">
|
||||
<line dasharray="13,135" stipple="5" stipple-stroke="#ffffff"
|
||||
stroke="#eccc68" use="boundaryType" />
|
||||
</m>
|
||||
<m v="6">
|
||||
<line dasharray="13,135" stipple="5" stipple-stroke="#ffffff"
|
||||
stroke="#0000ff" use="boundaryType" />
|
||||
</m>
|
||||
<m v="7">
|
||||
<line dasharray="13,135" stipple="5" stipple-stroke="#ffffff"
|
||||
stroke="#00ff00" use="boundaryType" />
|
||||
</m>
|
||||
<m v="9">
|
||||
<line dasharray="13,135" stipple="5" stipple-stroke="#ffffff"
|
||||
stroke="#8e44ad" use="boundaryType" />
|
||||
</m>
|
||||
</m>
|
||||
<m k="markColor" v="2">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#eccc68" width="0.1"/>
|
||||
</m>
|
||||
<!--导流区边线-->
|
||||
<m v="4">
|
||||
<line outline="boundary" stroke="#545D6C"></line>
|
||||
<lineSymbol repeat-gap="0.5" repeat-start="0"
|
||||
src="assets:omdb/icon_right.png" />
|
||||
|
||||
<m k="markColor" v="6">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#0000ff" width="0.1"/>
|
||||
</m>
|
||||
<!-- <!–铺设路面边缘–>-->
|
||||
<!-- <m v="5">-->
|
||||
<!-- <line outline="#ffffff" fix="true" src="assets:omdb/icon_close.png" stroke="#ffffffff" use="boundaryType"/>-->
|
||||
<!-- </m>-->
|
||||
|
||||
<m k="markColor" v="7">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#00ff00" width="0.1"/>
|
||||
</m>
|
||||
|
||||
<m k="markColor" v="0|9">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#8e44ad" width="0.1"/>
|
||||
</m>
|
||||
|
||||
</m>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<m k="boundaryType" v="0|3|4|5|6|7|8|9">
|
||||
<line stroke="#ffffff" use="boundaryType" />
|
||||
</m>
|
||||
<!--只区分虚线与实线-->
|
||||
<m k="boundaryType" v="1">
|
||||
<line dasharray="12,6" repeat-start="0" stroke="#ffffff" width="0.1"/>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--隧道-->
|
||||
<m v="OMDB_TUNNEL" zoom-max="19">
|
||||
<m k="formOfWay">
|
||||
<line dasharray="0.2,0.2" stroke="#d4237a" width="0.2" />
|
||||
</m>
|
||||
<m k="type" v="s_2_p">
|
||||
<symbol repeat="false" repeat-start="0" rotate="false"
|
||||
src="assets:omdb/icon_2202_0.svg" symbol-height="32" symbol-width="32"></symbol>
|
||||
</m>
|
||||
<m k="type" v="e_2_p">
|
||||
<symbol repeat="false" repeat-start="0" rotate="false"
|
||||
src="assets:omdb/icon_2202_1.svg" symbol-height="32" symbol-width="32"></symbol>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--道路方向-->
|
||||
<m v="OMDB_LINK_DIRECT">
|
||||
<m k="direct">
|
||||
<m v="2">
|
||||
<!-- <lineSymbol src="assets:omdb/oneway_right.svg"></lineSymbol>-->
|
||||
<lineSymbol src="assets:omdb/oneway_right.svg"></lineSymbol>
|
||||
</m>
|
||||
<m v="3">
|
||||
<!-- <lineSymbol src="assets:omdb/oneway_left.svg"></lineSymbol>-->
|
||||
<lineSymbol src="assets:omdb/oneway_left.svg"></lineSymbol>
|
||||
</m>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--交通灯-->
|
||||
<m v="OMDB_TRAFFICLIGHT">
|
||||
<m v="OMDB_TRAFFICLIGHT" zoom-max="19">
|
||||
<symbol repeat="false" rotate="false" src="assets:omdb/icon_4022_0.svg"
|
||||
symbol-height="69" symbol-width="69"></symbol>
|
||||
</m>
|
||||
|
||||
<!--普通交限-->
|
||||
<m v="OMDB_RESTRICTION">
|
||||
<m v="OMDB_RESTRICTION" zoom-max="19">
|
||||
<m k="angle">
|
||||
<symbol repeat="false" repeat-start="0" rotate="false"
|
||||
src="assets:omdb/icon_4006_0.svg" symbol-height="69" symbol-width="69"></symbol>
|
||||
@@ -1803,12 +1702,9 @@
|
||||
<line use="s2e" />
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!--电子眼-->
|
||||
<m v="OMDB_ELECTRONICEYE">
|
||||
<!-- <m k="angle">-->
|
||||
<!-- <symbol repeat="false" repeat-start="0" rotate="false"-->
|
||||
<!-- src="assets:symbols/volcano.svg" symbol-height="69" symbol-width="69"></symbol>-->
|
||||
<!-- </m>-->
|
||||
<m v="OMDB_ELECTRONICEYE" zoom-max="19">
|
||||
<caption dy="-30" fill="#000000" k="name" priority="0" size="14"
|
||||
stroke="#ffffff" stroke-width="1.0"></caption>
|
||||
<m k="type" v="angle">
|
||||
@@ -1819,8 +1715,9 @@
|
||||
<line use="s2e" />
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!-- 路口 -->
|
||||
<m v="OMDB_INTERSECTION">
|
||||
<m v="OMDB_INTERSECTION" zoom-max="19">
|
||||
<m k="type" v="node">
|
||||
<symbol src="assets:symbols/dot_blue_dark.svg"></symbol>
|
||||
</m>
|
||||
@@ -1828,424 +1725,424 @@
|
||||
<symbol src="assets:symbols/dot_magenta.svg"></symbol>
|
||||
</m>
|
||||
</m>
|
||||
|
||||
<!-- 道路名 -->
|
||||
<m v="OMDB_LINK_NAME">
|
||||
<text use="road"></text>
|
||||
</m>
|
||||
|
||||
<!-- 车信 -->
|
||||
<m v="OMDB_LANEINFO">
|
||||
<m v="OMDB_LANEINFO" zoom-max="19">
|
||||
<m k="currentType" v="0">
|
||||
<m k="currentDirect" v="1">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_1_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_1_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_4_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_4_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_4_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_4_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_5_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_5_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/normal/1301_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/normal/1301_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
</m>
|
||||
<m k="currentType" v="1">
|
||||
<m k="currentDirect" v="0">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_0.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_0.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_1_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_1_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_4_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_4_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_4_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_4_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_5_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_5_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/extend/1301_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/extend/1301_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
</m>
|
||||
<m k="currentType" v="2">
|
||||
<m k="currentDirect" v="0">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_0.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_0.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="1_7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_1_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_1_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="2_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_2_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_2_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_3.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_3.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_3_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_3_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_3_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_3_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="3_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_3_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_3_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_4.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_4.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_4_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_4_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="4_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_4_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_4_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_5.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_5.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="5_6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_5_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_5_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="6">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_6.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_6.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
<m k="currentDirect" v="7">
|
||||
<symbol repeat="false" repeat-start="0" repeat-gap="2000"
|
||||
src="assets:omdb/4601/bus/1301_7.svg" symbol-height="29" symbol-width="29"></symbol>
|
||||
src="assets:omdb/4601/bus/1301_7.svg" symbol-height="24" symbol-width="24"></symbol>
|
||||
</m>
|
||||
</m>
|
||||
</m>
|
||||
<m v="OMDB_AREA">
|
||||
<area use="water" repeat="true" src="assets:omdb/area_test.jpg" stroke="#ff0000" stroke-width="2"></area>
|
||||
</m>
|
||||
<m k="type" v="s_2_e">
|
||||
<line use="s2e" />
|
||||
</m>
|
||||
|
||||
<m v="OMDB_POLE">
|
||||
<line stroke="#0000ff" width="0.1" cap="butt"></line>
|
||||
<line stroke="#0000ff" width="2" cap="butt"></line>
|
||||
</m>
|
||||
|
||||
<m v="OMDB_TRAFFIC_SIGN">
|
||||
<area use="water" repeat="false" stroke="#ff0000" stroke-width="2"></area>
|
||||
</m>
|
||||
|
||||
<m v="OMDB_AREA">
|
||||
<area use="water" repeat="true" src="assets:omdb/area_test.jpg" stroke="#ff0000" stroke-width="2"></area>
|
||||
</m>
|
||||
</m>
|
||||
</rendertheme>
|
||||
1
collect-library/src/main/assets/omdb/icon_1012_0.svg
Normal file
@@ -0,0 +1 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?><svg id="b" xmlns="http://www.w3.org/2000/svg" width="124.7" height="124.7" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 124.7 124.7"><defs><style>.i{fill:url(#f);}.j{fill:#fff;}.k{fill:#1566e8;}.l,.m{fill:#535a60;}.n{fill:#262d34;isolation:isolate;opacity:.2;}.o{fill:url(#g);stroke:#8b9fae;stroke-miterlimit:10;stroke-width:1px;}.m{opacity:0;}</style><linearGradient id="f" x1="60.1" y1="50.4" x2="64.9" y2="50.4" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#989898"/><stop offset="0" stop-color="#a3a3a3"/><stop offset=".1" stop-color="#c4c5c5"/><stop offset=".2" stop-color="#d8d9d9"/><stop offset=".3" stop-color="#e0e1e1"/><stop offset=".4" stop-color="#dbdcdc"/><stop offset=".5" stop-color="#cccece"/><stop offset=".6" stop-color="#b5b6b7"/><stop offset=".7" stop-color="#949697"/><stop offset=".8" stop-color="#6a6c6f"/><stop offset=".8" stop-color="#3f4246"/><stop offset="1" stop-color="#404247"/><stop offset="1" stop-color="#43434a"/></linearGradient><linearGradient id="g" x1="40.1" y1="23.8" x2="84.6" y2="23.8" gradientUnits="userSpaceOnUse"><stop offset="0" stop-color="#afbacb"/><stop offset=".1" stop-color="#c1ccda"/><stop offset=".4" stop-color="#d9e6f0"/><stop offset=".5" stop-color="#e3f0f8"/><stop offset=".6" stop-color="#dde9f2"/><stop offset=".8" stop-color="#ccd8e4"/><stop offset="1" stop-color="#b1bbcc"/><stop offset="1" stop-color="#aeb8c9"/></linearGradient></defs><g id="c"><g><rect class="m" y="0" width="124.7" height="124.7"/><g><ellipse id="d" class="n" cx="62.4" cy="61.8" rx="14.4" ry="3.7"/><ellipse id="e" class="l" cx="62.4" cy="61.8" rx="7.5" ry="3"/><path class="i" d="M62.4,38.3h0c1.4,0,2.6,1.2,2.6,2.6v19.2c0,1.4-1.1,2.5-2.5,2.5h-.3c-1.4,0-2.5-1.1-2.5-2.5v-19.3c0-1.4,1.2-2.6,2.6-2.6Z"/><rect class="o" x="40.1" y=".5" width="44.5" height="46.6" rx="14.4" ry="14.4"/><rect class="k" x="40.6" y="2.6" width="43.5" height="44" rx="14.1" ry="14.1"/><path id="h" class="j" d="M46,11.4c-.3,0-.6-.2-.7-.4s0-.6,.1-.8c1.3-1.6,3-2.9,4.8-3.9,.2,0,.4-.1,.6,0,.2,0,.4,.2,.5,.4,.2,.4,0,.9-.3,1.1-1.7,.9-3.1,2.1-4.3,3.5-.2,.2-.4,.3-.6,.3h0Zm-1.8,2.6c-.1,0-.3,0-.4-.1-.2-.1-.3-.3-.4-.5,0-.2,0-.4,.1-.6l.3-.4c.1-.2,.3-.3,.5-.4,.2,0,.4,0,.6,0,.2,.1,.3,.3,.4,.5s0,.4-.1,.6l-.3,.4c-.1,.2-.4,.4-.7,.4h0Z"/><g><path class="j" d="M61,23.3c-.3-.1-.7-.4-1.2-.7,0,0-.2,0-.2-.1v1.5h-7.1v-1.4c-.2,.2-.5,.4-.9,.7-.1,0-.2,.2-.3,.2-.3-.5-.5-1.1-.9-1.6,.2,0,.4-.2,.6-.3h-1.6v1.8c.7,.5,1.4,1.1,2.1,1.7l-.9,1.4-1.2-1.2v7.3h-1.6v-7.6c-.4,1.3-1,2.5-1.8,3.8,0-.6-.2-1.4-.4-2.3,.9-1.5,1.6-3.2,2.2-4.9h-1.8v-1.5h1.8v-3.2h1.6v3.2h1.6v1.5c1.9-1.2,3.4-2.8,4.4-4.9h1.8c0,.1-.3,.9-.3,.9,1.4,1.8,3,3.2,4.8,4.1-.3,.5-.5,1.1-.7,1.6Zm-10.3,8.5v-1.4h6.6c.4-1,.8-2.4,1.4-4.4,.1-.5,.2-.9,.3-1.1l1.6,.4c-.1,.4-.3,1-.6,1.7-.5,1.5-.9,2.6-1.2,3.4h2.4v1.4h-10.6Zm2-2c-.4-1.4-.8-2.9-1.2-4.3l1.4-.3c.5,1.3,.9,2.7,1.3,4.2l-1.5,.4Zm3.3-10.8c-.9,1.3-2,2.5-3.3,3.5h6.9c-1.5-1.1-2.7-2.3-3.5-3.5Zm-.3,10.1c-.2-1.1-.5-2.5-1-4l1.5-.3c.4,1.3,.7,2.7,.9,4l-1.4,.3Z"/><path class="j" d="M77.8,23.9c-.5-.1-1-.3-1.4-.5v6.1h-11.6v-6c-.1,0-.3,.1-.5,.2-.4,.2-.8,.3-1.1,.4,0-.2-.2-.6-.4-1.1,0-.2-.2-.4-.2-.5,2.4-.7,4.4-1.6,6-2.7h-5.6v-1.4h6.6v-1.5h1.7v1.5h6.6v1.4h-5.6c1.6,1.1,3.6,2,6,2.6l-.7,1.6Zm-15.1,8.1v-1.3h15.6v1.3h-15.6Zm7-9.5v-2c-1.3,1.1-2.6,1.9-3.9,2.5h9.7c-1.6-.7-3-1.6-4-2.6v2h-1.7Zm-3.2,1.8v1.3h8.1v-1.3h-8.1Zm0,2.4v1.3h8.1v-1.3h-8.1Z"/></g></g></g></g></svg>
|
||||
|
After Width: | Height: | Size: 3.3 KiB |
1
collect-library/src/main/assets/omdb/icon_2083_0.svg
Normal file
@@ -0,0 +1 @@
|
||||
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1689041545166" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="30665" width="16" height="16" xmlns:xlink="http://www.w3.org/1999/xlink"><path d="M512.005117 958.708971C265.683035 958.708971 65.290005 758.316965 65.290005 511.99386c0-246.310825 200.39303-446.703855 446.715111-446.703855 246.310825 0 446.703855 200.39303 446.703855 446.703855C958.708971 758.316965 758.316965 958.708971 512.005117 958.708971zM512.005117 169.716356c-188.738595 0-342.289784 153.545048-342.289784 342.277504 0 188.738595 153.551188 342.289784 342.289784 342.289784 188.733479 0 342.278527-153.551188 342.278527-342.289784C854.283644 323.261405 700.738595 169.716356 512.005117 169.716356z" p-id="30666" fill="#fcba5a"></path></svg>
|
||||
|
After Width: | Height: | Size: 900 B |
13
collect-library/src/main/assets/omdb/icon_2083_6.svg
Normal file
@@ -0,0 +1,13 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="4" height="58.142" viewBox="0 0 4 58.142">
|
||||
<defs>
|
||||
<style>.a{fill:none;stroke:#ebb972;stroke-width:4px;}.b{opacity:0.001;}</style>
|
||||
</defs>
|
||||
<g transform="translate(-401.035 -35.964)">
|
||||
<g transform="translate(313.535 166.535) rotate(-90)">
|
||||
<line class="a" x2="29.071" transform="translate(101.5 89.5)" />
|
||||
</g>
|
||||
<g class="b" transform="translate(313.535 195.605) rotate(-90)">
|
||||
<line class="a" x2="29.071" transform="translate(101.5 89.5)" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 580 B |
10
collect-library/src/main/assets/omdb/icon_2083_7.svg
Normal file
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<svg id="b" xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32">
|
||||
<defs>
|
||||
<style>.e{fill:#fcba5a;}</style>
|
||||
</defs>
|
||||
<g id="c">
|
||||
<path id="d" class="e"
|
||||
d="M31.9,0l-14.3,23.2-1.6,2.6-1.6-2.6L0,0h0V6.1L14.1,28.9l1.9,3.1h0s1.9-3.1,1.9-3.1L32,6V0h0Z" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 365 B |
8
collect-library/src/main/assets/omdb/icon_2083_7_1.svg
Normal file
@@ -0,0 +1,8 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32">
|
||||
<defs>
|
||||
<style>.a{fill:#fcba5a;}</style>
|
||||
</defs>
|
||||
<path class="a"
|
||||
d="M31.94,0,17.6,23.21l-1.62,2.622L14.4,23.274.021,0H0V6.084L14.09,28.891l1.869,3.094.024.015,1.888-3.109L32,6.021V0Z"
|
||||
transform="translate(0 0)" />
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 339 B |
6
collect-library/src/main/assets/omdb/icon_2083_9.svg
Normal file
@@ -0,0 +1,6 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="15" height="48" viewBox="0 0 15 48">
|
||||
<defs>
|
||||
<style>.a{fill:#ebb972;}</style>
|
||||
</defs>
|
||||
<rect class="a" width="15" height="48" rx="7.5" />
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 209 B |
18
collect-library/src/main/assets/omdb/icon_2202_0.svg
Normal file
@@ -0,0 +1,18 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">
|
||||
<defs>
|
||||
<style>
|
||||
.a{fill:#fceaa0;stroke:#1b23b4;stroke-width:3px;}.b{fill:#1b23b4;}.c{stroke:none;}.d{fill:none;}
|
||||
</style>
|
||||
</defs>
|
||||
<g transform="translate(-126 -381)">
|
||||
<g transform="translate(9304 7585)">
|
||||
<g class="a" transform="translate(-9178 -7204)">
|
||||
<circle class="c" cx="40" cy="40" r="40" />
|
||||
<circle class="d" cx="40" cy="40" r="38.5" />
|
||||
</g>
|
||||
</g>
|
||||
<path class="b"
|
||||
d="M257.043,173.635V146.2c0-9.344-8.378-16.918-18.708-16.918s-18.712,7.574-18.712,16.918v27.436H214.94V145.378c0-11.808,10.6-21.378,23.684-21.378s23.683,9.57,23.683,21.378v28.257Zm-18.13-42.773c13.594-.133,16.377,13.195,16.377,13.195v29.579H254.7l-9.934-14.271V144.584s-.436-4.223-5.851-4.223-6.431,4.223-6.431,4.223v14.779l-10.2,14.271h-.913V144.06S223.714,131.009,238.913,130.861Zm5.049,28.5,10.159,14.271h-31.21l10.159-14.272h10.893Zm0,0"
|
||||
transform="translate(-72.624 269.184)" />
|
||||
</g>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.1 KiB |
1
collect-library/src/main/assets/omdb/icon_2202_1.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80"><defs><style>.a{fill:#1b23b4;stroke:#fceaa0;stroke-width:3px;}.b{fill:#fceaa0;}.c{stroke:none;}.d{fill:none;}</style></defs><g transform="translate(-268 -381)"><g transform="translate(9446 7585)"><g class="a" transform="translate(-9178 -7204)"><circle class="c" cx="40" cy="40" r="40"/><circle class="d" cx="40" cy="40" r="38.5"/></g></g><path class="b" d="M257.043,173.635V146.2c0-9.344-8.378-16.918-18.708-16.918s-18.712,7.574-18.712,16.918v27.436H214.94V145.378c0-11.808,10.6-21.378,23.684-21.378s23.683,9.57,23.683,21.378v28.257Zm-18.13-42.773c13.594-.133,16.377,13.195,16.377,13.195v29.579H254.7l-9.934-14.271V144.584s-.436-4.223-5.851-4.223-6.431,4.223-6.431,4.223v14.779l-10.2,14.271h-.913V144.06S223.714,131.009,238.913,130.861Zm5.049,28.5,10.159,14.271h-31.21l10.159-14.272h10.893Zm0,0" transform="translate(69.376 269.184)"/></g></svg>
|
||||
|
After Width: | Height: | Size: 928 B |
@@ -1 +1,45 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="136" height="136" viewBox="0 0 136 136"><defs><style>.a,.f{fill:#fff;}.a{opacity:0;}.b{fill:#ff5f4c;opacity:0.304;}.c{fill:#a74d4b;opacity:0.708;}.d{fill:url(#a);}.e{fill:url(#b);}.g{fill:#2a23f5;stroke:#db4646;stroke-linecap:square;stroke-width:3px;stroke-dasharray:9 10;}.h{stroke:none;}.i{fill:none;}</style><radialGradient id="a" cx="0.21" cy="0.134" r="1.274" gradientTransform="matrix(0.849, 0.529, -0.307, 0.493, 0.073, -0.043)" gradientUnits="objectBoundingBox"><stop offset="0" stop-color="#ff9287"/><stop offset="0.786" stop-color="#ff5f4c"/><stop offset="1" stop-color="#ff5f4c"/></radialGradient><radialGradient id="b" cx="0.5" cy="0.5" r="0.5" gradientUnits="objectBoundingBox"><stop offset="0" stop-color="#e75545"/><stop offset="0.793" stop-color="#c4483b"/><stop offset="1" stop-color="#983b31"/></radialGradient></defs><g transform="translate(-956 -396)"><rect class="a" width="136" height="136" transform="translate(956 396)"/><g transform="translate(989.164 429.346)"><g transform="translate(10.653 81.66)"><ellipse class="b" cx="24.183" cy="8.497" rx="24.183" ry="8.497"/><ellipse class="c" cx="8.497" cy="3.268" rx="8.497" ry="3.268" transform="translate(15.687 5.229)"/></g><g transform="translate(0 0)"><path class="d" d="M22.956,71.538q-.792-.8-1.543-1.533A36.466,36.466,0,0,1,0,36.4C0,16.3,15.6,0,34.837,0S69.673,16.3,69.673,36.4c0,15.235-8.954,28.283-21.664,33.711q-.588.673-1.219,1.424A73.582,73.582,0,0,0,35.337,90.157S30.335,78.981,22.956,71.538Z" transform="translate(0 0)"/><circle class="e" cx="27.451" cy="27.451" r="27.451" transform="translate(7.029 7.568)"/></g></g><g transform="translate(10096 7643)"><circle class="f" cx="28" cy="28" r="28" transform="translate(-9100 -7207)"/><g class="g" transform="translate(-9096 -7203)"><circle class="h" cx="24" cy="24" r="24"/><circle class="i" cx="24" cy="24" r="25.5"/></g></g></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="136"
|
||||
height="136" viewBox="0 0 136 136">
|
||||
<defs>
|
||||
<style>
|
||||
.a,.f{fill:#fff;}.a{opacity:0;}.b{fill:#ff5f4c;opacity:0.304;}.c{fill:#a74d4b;opacity:0.708;}.d{fill:url(#a);}.e{fill:url(#b);}.g{fill:#2a23f5;stroke:#db4646;stroke-linecap:square;stroke-width:3px;stroke-dasharray:9
|
||||
10;}.h{stroke:none;}.i{fill:none;}
|
||||
</style>
|
||||
<radialGradient id="a" cx="0.21" cy="0.134" r="1.274"
|
||||
gradientTransform="matrix(0.849, 0.529, -0.307, 0.493, 0.073, -0.043)"
|
||||
gradientUnits="objectBoundingBox">
|
||||
<stop offset="0" stop-color="#ff9287" />
|
||||
<stop offset="0.786" stop-color="#ff5f4c" />
|
||||
<stop offset="1" stop-color="#ff5f4c" />
|
||||
</radialGradient>
|
||||
<radialGradient id="b" cx="0.5" cy="0.5" r="0.5" gradientUnits="objectBoundingBox">
|
||||
<stop offset="0" stop-color="#e75545" />
|
||||
<stop offset="0.793" stop-color="#c4483b" />
|
||||
<stop offset="1" stop-color="#983b31" />
|
||||
</radialGradient>
|
||||
</defs>
|
||||
<g transform="translate(-956 -396)">
|
||||
<rect class="a" width="136" height="136" transform="translate(956 396)" />
|
||||
<g transform="translate(989.164 429.346)">
|
||||
<g transform="translate(10.653 81.66)">
|
||||
<ellipse class="b" cx="24.183" cy="8.497" rx="24.183" ry="8.497" />
|
||||
<ellipse class="c" cx="8.497" cy="3.268" rx="8.497" ry="3.268"
|
||||
transform="translate(15.687 5.229)" />
|
||||
</g>
|
||||
<g transform="translate(0 0)">
|
||||
<path class="d"
|
||||
d="M22.956,71.538q-.792-.8-1.543-1.533A36.466,36.466,0,0,1,0,36.4C0,16.3,15.6,0,34.837,0S69.673,16.3,69.673,36.4c0,15.235-8.954,28.283-21.664,33.711q-.588.673-1.219,1.424A73.582,73.582,0,0,0,35.337,90.157S30.335,78.981,22.956,71.538Z"
|
||||
transform="translate(0 0)" />
|
||||
<circle class="e" cx="27.451" cy="27.451" r="27.451"
|
||||
transform="translate(7.029 7.568)" />
|
||||
</g>
|
||||
</g>
|
||||
<g transform="translate(10096 7643)">
|
||||
<circle class="f" cx="28" cy="28" r="28" transform="translate(-9100 -7207)" />
|
||||
<g class="g" transform="translate(-9096 -7203)">
|
||||
<circle class="h" cx="24" cy="24" r="24" />
|
||||
<circle class="i" cx="24" cy="24" r="25.5" />
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 2.4 KiB |
@@ -1 +1,24 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="56" height="74.999" viewBox="0 0 56 74.999"><defs><style>.a{fill:#fff;opacity:0;}.b{fill:#fad950;}.c,.d{fill:#0b1923;}.c{stroke:#0b1923;stroke-width:0.5px;}.e,.f{stroke:none;}.f{fill:#0b1923;}</style></defs><g transform="translate(1401 -1261.001) rotate(90)"><rect class="a" width="56" height="56" transform="translate(1280 1345)"/><g transform="translate(0 -2)"><g class="b" transform="translate(1280 1349)"><path class="e" d="M 52.55363845825195 47.5 L 3.446360111236572 47.5 C 3.195830106735229 47.5 3.067879915237427 47.34397125244141 3.0139000415802 47.25096893310547 C 2.959929943084717 47.157958984375 2.887939929962158 46.96945190429688 3.012239933013916 46.75191879272461 L 27.56587028503418 3.783060550689697 C 27.69112968444824 3.563860416412354 27.89163017272949 3.53113055229187 28 3.53113055229187 C 28.10836029052734 3.53113055229187 28.30886077880859 3.563860416412354 28.43411064147949 3.783050537109375 L 52.98777008056641 46.75193023681641 C 53.112060546875 46.96945190429688 53.04006958007812 47.157958984375 52.98609924316406 47.25096893310547 C 52.93212127685547 47.34397125244141 52.80416870117188 47.5 52.55363845825195 47.5 Z"/><path class="f" d="M 27.99999618530273 6.046699523925781 L 5.169540405273438 46 L 50.83046340942383 46 L 27.99999618530273 6.046699523925781 M 27.99999809265137 2.0311279296875 C 28.67629432678223 2.0311279296875 29.35259056091309 2.367034912109375 29.73648071289062 3.038848876953125 L 54.29013061523438 46.00772094726562 C 55.05202102661133 47.34104156494141 54.08929061889648 49 52.55363845825195 49 L 3.446361541748047 49 C 1.910709381103516 49 0.9479789733886719 47.34104156494141 1.709869384765625 46.00772094726562 L 26.26350975036621 3.038848876953125 C 26.64740562438965 2.367034912109375 27.32370185852051 2.0311279296875 27.99999809265137 2.0311279296875 Z"/></g><path class="c" d="M44.849,49.162a.812.812,0,0,0,.794-.794V46.779H48.2a4.526,4.526,0,0,0,3.462-1.419,5.191,5.191,0,0,0,1.248-3.178,2.467,2.467,0,0,0,2.213-2.667c-.113-3.235-3.235-4.483-5.221-4.483H40.309a5.77,5.77,0,0,0-5.278,5.618v1.475a1.138,1.138,0,0,0,1.135,1.135h.34c.113,2.043,1.305,3.518,2.951,3.518h1.873v1.589a.812.812,0,0,0,.794.794h.908v.624a2.519,2.519,0,0,0,2.5,2.5h.738v1.362a1.5,1.5,0,0,0,1.475,1.475H50.41a1.5,1.5,0,0,0,1.475-1.475V50.127a1.5,1.5,0,0,0-1.475-1.475H47.743a1.5,1.5,0,0,0-1.475,1.475v1.362H45.53a1.707,1.707,0,0,1-1.7-1.7v-.624Zm2.213,4.483V52.283c1.873,0,1.873-.794,0-.794ZM37.3,43.2h6.242a2.894,2.894,0,0,0,1.759-.624,2.984,2.984,0,0,0,1.021,1.589,3.224,3.224,0,0,0,2.1.794h.4c1.532-.284,2.44-1.589,2.44-3.575a4,4,0,0,0-1.816-3.745,6.605,6.605,0,0,1,.851-.34.413.413,0,1,0-.227-.794,3.922,3.922,0,0,0-1.532.794l-.057.057a6.481,6.481,0,0,0-1.532,2.1c-.738,1.419-2.1,2.951-3.4,2.951H36.167a.366.366,0,0,1-.34-.34V40.593a4.919,4.919,0,0,1,4.483-4.824H49.9c1.135,0,4.313.681,4.426,3.689a1.7,1.7,0,0,1-1.419,1.873,6.868,6.868,0,0,0-.057-1.078.4.4,0,1,0-.794.113,5.661,5.661,0,0,1-1.021,4.426,3.6,3.6,0,0,1-2.894,1.192H39.458C38.266,45.984,37.415,44.849,37.3,43.2Zm4.824,3.575h2.667v1.589H42.125Z" transform="translate(1262.925 1337.469)"/></g><path class="d" d="M69.876,257.508H31.287a2.233,2.233,0,1,1,0-4.466H69.876a2.233,2.233,0,1,1,0,4.466Zm1.217-.951-9.7-8.471a2.2,2.2,0,0,1,0-3.157,2.328,2.328,0,0,1,3.234,0l9.705,8.471a2.2,2.2,0,0,1,0,3.157A2.325,2.325,0,0,1,71.093,256.557Zm-9.7,5.908,9.7-8.471a2.328,2.328,0,0,1,3.234,0,2.2,2.2,0,0,1,0,3.157l-9.7,8.471a2.328,2.328,0,0,1-3.234,0A2.2,2.2,0,0,1,61.392,262.465Z" transform="translate(1016.726 1425) rotate(-90)"/></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="56" height="74.999" viewBox="0 0 56 74.999">
|
||||
<defs>
|
||||
<style>
|
||||
.a{fill:#fff;opacity:0;}.b{fill:#fad950;}.c,.d{fill:#0b1923;}.c{stroke:#0b1923;stroke-width:0.5px;}.e,.f{stroke:none;}.f{fill:#0b1923;}
|
||||
</style>
|
||||
</defs>
|
||||
<g transform="translate(1401 -1261.001) rotate(90)">
|
||||
<rect class="a" width="56" height="56" transform="translate(1280 1345)" />
|
||||
<g transform="translate(0 -2)">
|
||||
<g class="b" transform="translate(1280 1349)">
|
||||
<path class="e"
|
||||
d="M 52.55363845825195 47.5 L 3.446360111236572 47.5 C 3.195830106735229 47.5 3.067879915237427 47.34397125244141 3.0139000415802 47.25096893310547 C 2.959929943084717 47.157958984375 2.887939929962158 46.96945190429688 3.012239933013916 46.75191879272461 L 27.56587028503418 3.783060550689697 C 27.69112968444824 3.563860416412354 27.89163017272949 3.53113055229187 28 3.53113055229187 C 28.10836029052734 3.53113055229187 28.30886077880859 3.563860416412354 28.43411064147949 3.783050537109375 L 52.98777008056641 46.75193023681641 C 53.112060546875 46.96945190429688 53.04006958007812 47.157958984375 52.98609924316406 47.25096893310547 C 52.93212127685547 47.34397125244141 52.80416870117188 47.5 52.55363845825195 47.5 Z" />
|
||||
<path class="f"
|
||||
d="M 27.99999618530273 6.046699523925781 L 5.169540405273438 46 L 50.83046340942383 46 L 27.99999618530273 6.046699523925781 M 27.99999809265137 2.0311279296875 C 28.67629432678223 2.0311279296875 29.35259056091309 2.367034912109375 29.73648071289062 3.038848876953125 L 54.29013061523438 46.00772094726562 C 55.05202102661133 47.34104156494141 54.08929061889648 49 52.55363845825195 49 L 3.446361541748047 49 C 1.910709381103516 49 0.9479789733886719 47.34104156494141 1.709869384765625 46.00772094726562 L 26.26350975036621 3.038848876953125 C 26.64740562438965 2.367034912109375 27.32370185852051 2.0311279296875 27.99999809265137 2.0311279296875 Z" />
|
||||
</g>
|
||||
<path class="c"
|
||||
d="M44.849,49.162a.812.812,0,0,0,.794-.794V46.779H48.2a4.526,4.526,0,0,0,3.462-1.419,5.191,5.191,0,0,0,1.248-3.178,2.467,2.467,0,0,0,2.213-2.667c-.113-3.235-3.235-4.483-5.221-4.483H40.309a5.77,5.77,0,0,0-5.278,5.618v1.475a1.138,1.138,0,0,0,1.135,1.135h.34c.113,2.043,1.305,3.518,2.951,3.518h1.873v1.589a.812.812,0,0,0,.794.794h.908v.624a2.519,2.519,0,0,0,2.5,2.5h.738v1.362a1.5,1.5,0,0,0,1.475,1.475H50.41a1.5,1.5,0,0,0,1.475-1.475V50.127a1.5,1.5,0,0,0-1.475-1.475H47.743a1.5,1.5,0,0,0-1.475,1.475v1.362H45.53a1.707,1.707,0,0,1-1.7-1.7v-.624Zm2.213,4.483V52.283c1.873,0,1.873-.794,0-.794ZM37.3,43.2h6.242a2.894,2.894,0,0,0,1.759-.624,2.984,2.984,0,0,0,1.021,1.589,3.224,3.224,0,0,0,2.1.794h.4c1.532-.284,2.44-1.589,2.44-3.575a4,4,0,0,0-1.816-3.745,6.605,6.605,0,0,1,.851-.34.413.413,0,1,0-.227-.794,3.922,3.922,0,0,0-1.532.794l-.057.057a6.481,6.481,0,0,0-1.532,2.1c-.738,1.419-2.1,2.951-3.4,2.951H36.167a.366.366,0,0,1-.34-.34V40.593a4.919,4.919,0,0,1,4.483-4.824H49.9c1.135,0,4.313.681,4.426,3.689a1.7,1.7,0,0,1-1.419,1.873,6.868,6.868,0,0,0-.057-1.078.4.4,0,1,0-.794.113,5.661,5.661,0,0,1-1.021,4.426,3.6,3.6,0,0,1-2.894,1.192H39.458C38.266,45.984,37.415,44.849,37.3,43.2Zm4.824,3.575h2.667v1.589H42.125Z"
|
||||
transform="translate(1262.925 1337.469)" />
|
||||
</g>
|
||||
<path class="d"
|
||||
d="M69.876,257.508H31.287a2.233,2.233,0,1,1,0-4.466H69.876a2.233,2.233,0,1,1,0,4.466Zm1.217-.951-9.7-8.471a2.2,2.2,0,0,1,0-3.157,2.328,2.328,0,0,1,3.234,0l9.705,8.471a2.2,2.2,0,0,1,0,3.157A2.325,2.325,0,0,1,71.093,256.557Zm-9.7,5.908,9.7-8.471a2.328,2.328,0,0,1,3.234,0,2.2,2.2,0,0,1,0,3.157l-9.7,8.471a2.328,2.328,0,0,1-3.234,0A2.2,2.2,0,0,1,61.392,262.465Z"
|
||||
transform="translate(1016.726 1425) rotate(-90)" />
|
||||
</g>
|
||||
</svg>
|
||||
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.8 KiB |
@@ -46,4 +46,10 @@ public interface INiLocationDao {
|
||||
|
||||
@Query("SELECT * FROM niLocation")
|
||||
List<NiLocation> findAll();
|
||||
|
||||
@Query("SELECT * FROM niLocation where time>=:startTime and time<=:endTime and taskId=:taskId")
|
||||
List<NiLocation> taskIdAndTimeTofindList(String taskId,long startTime,long endTime);
|
||||
|
||||
@Query("SELECT * FROM niLocation where taskId =:taskId")
|
||||
List<NiLocation> findToTaskIdAll(String taskId);
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ import java.util.UUID;
|
||||
* @Date 2022/4/14
|
||||
* @Description: ${TODO}(数据基类)
|
||||
*/
|
||||
public class Feature implements Serializable, Cloneable {
|
||||
public class Feature extends Object implements Serializable, Cloneable {
|
||||
// //主键
|
||||
// @PrimaryKey(autoGenerate = true)
|
||||
// public int rowId;
|
||||
|
||||
@@ -1,8 +1,13 @@
|
||||
package com.navinfo.collect.library.data.entity
|
||||
|
||||
import io.realm.RealmObject
|
||||
import io.realm.annotations.PrimaryKey
|
||||
|
||||
open class HadLinkDvoBean @JvmOverloads constructor(
|
||||
/**
|
||||
* 任务id,方便捕捉查询
|
||||
*/
|
||||
var taskId: Int = 0,
|
||||
/**
|
||||
* 图幅号
|
||||
*/
|
||||
@@ -10,6 +15,7 @@ open class HadLinkDvoBean @JvmOverloads constructor(
|
||||
/**
|
||||
* linkPid
|
||||
*/
|
||||
@PrimaryKey
|
||||
var linkPid: String = "",
|
||||
/**
|
||||
* (几何)加偏后
|
||||
@@ -19,6 +25,18 @@ open class HadLinkDvoBean @JvmOverloads constructor(
|
||||
/**
|
||||
* 不作业原因
|
||||
*/
|
||||
var reason: String = ""
|
||||
var reason: String = "",
|
||||
|
||||
/**
|
||||
* 1:源库link,2:选择link 3:现场新增
|
||||
*/
|
||||
var linkStatus: Int = 1,
|
||||
/**
|
||||
* 详细属性
|
||||
*/
|
||||
var linkInfo: LinkInfoBean? = null,
|
||||
/**
|
||||
* 长度(米)
|
||||
*/
|
||||
var length: Double = 0.000,
|
||||
) : RealmObject()
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.navinfo.collect.library.data.entity
|
||||
|
||||
import io.realm.RealmObject
|
||||
|
||||
/**
|
||||
* 道路信息
|
||||
*/
|
||||
open class LinkInfoBean @JvmOverloads constructor(
|
||||
/**
|
||||
* 种别
|
||||
*/
|
||||
var kind: Int = 0,
|
||||
/**
|
||||
* 功能等级
|
||||
*/
|
||||
var functionLevel: Int = 0,
|
||||
/**
|
||||
* 数据的等级
|
||||
*/
|
||||
var dataLevel: Int = 0,
|
||||
|
||||
/**
|
||||
* 备注信息
|
||||
*/
|
||||
var description: String = ""
|
||||
) : RealmObject()
|
||||
@@ -65,6 +65,10 @@ public class NiLocation extends Feature{
|
||||
private String groupId;
|
||||
@ColumnInfo(name = "timeStamp")
|
||||
private String timeStamp;
|
||||
@ColumnInfo(name = "media")
|
||||
private int media;
|
||||
@ColumnInfo(name = "taskId")
|
||||
private String taskId;
|
||||
|
||||
private boolean isAccouracy;
|
||||
private boolean isSpeed;
|
||||
@@ -318,4 +322,20 @@ public class NiLocation extends Feature{
|
||||
public void setTimeStamp(String timeStamp) {
|
||||
this.timeStamp = timeStamp;
|
||||
}
|
||||
|
||||
public int getMedia() {
|
||||
return media;
|
||||
}
|
||||
|
||||
public void setMedia(int media) {
|
||||
this.media = media;
|
||||
}
|
||||
|
||||
public String getTaskId() {
|
||||
return taskId;
|
||||
}
|
||||
|
||||
public void setTaskId(String taskId) {
|
||||
this.taskId = taskId;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.navinfo.collect.library.data.entity
|
||||
|
||||
import io.realm.RealmList
|
||||
import io.realm.RealmObject
|
||||
import io.realm.annotations.PrimaryKey
|
||||
|
||||
open class NoteBean @JvmOverloads constructor(
|
||||
@PrimaryKey
|
||||
var id: String = "",
|
||||
var guideGeometry: String = "",
|
||||
var description: String = "",
|
||||
var list: RealmList<SketchAttachContent> = RealmList<SketchAttachContent>(),
|
||||
) : RealmObject()
|
||||
@@ -15,6 +15,7 @@ import io.realm.annotations.PrimaryKey
|
||||
*/
|
||||
//@RealmClass
|
||||
open class QsRecordBean @JvmOverloads constructor(
|
||||
var taskId: Int = -1,
|
||||
/**
|
||||
* id 主键
|
||||
*
|
||||
@@ -64,7 +65,7 @@ open class QsRecordBean @JvmOverloads constructor(
|
||||
/**
|
||||
* 质检员ID
|
||||
*/
|
||||
var checkUserId: String = "张海球",
|
||||
var checkUserId: String = "",
|
||||
/**
|
||||
* 质检日期
|
||||
*/
|
||||
@@ -97,6 +98,7 @@ open class QsRecordBean @JvmOverloads constructor(
|
||||
|
||||
fun copy(): QsRecordBean {
|
||||
val qs = QsRecordBean(
|
||||
taskId = taskId,
|
||||
id = id,
|
||||
elementId = elementId,
|
||||
linkId = linkId,
|
||||
|
||||
@@ -23,6 +23,9 @@ open class ReferenceEntity() : RealmObject() {
|
||||
lateinit var name: String //要素名
|
||||
lateinit var table: String //要素表名
|
||||
var code: Int = 0 // 要素编码
|
||||
var zoomMin: Int = 18 //显示最小级别
|
||||
var zoomMax: Int = 23 //显示最大级别
|
||||
var taskId: Int = 0 //任务ID
|
||||
var geometry: String = "" // 要素渲染参考的geometry,该数据可能会在导入预处理环节被修改,原始geometry会保存在properties的geometry字段下
|
||||
get() {
|
||||
wkt = GeometryTools.createGeometry(field)
|
||||
|
||||
@@ -59,6 +59,9 @@ open class RenderEntity() : RealmObject(), Parcelable {
|
||||
var properties: RealmDictionary<String> = RealmDictionary()
|
||||
var tileX: RealmSet<Int> = RealmSet() // x方向的tile编码
|
||||
var tileY: RealmSet<Int> = RealmSet() // y方向的tile编码
|
||||
var taskId: Int = 0 //任务ID
|
||||
var zoomMin: Int = 18 //显示最小级别
|
||||
var zoomMax: Int = 23 //显示最大级别
|
||||
|
||||
constructor(name: String) : this() {
|
||||
this.name = name
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
package com.navinfo.collect.library.data.entity
|
||||
|
||||
import io.realm.RealmObject
|
||||
import io.realm.annotations.PrimaryKey
|
||||
|
||||
/**
|
||||
* @author zhjch
|
||||
* @version V1.0
|
||||
* @ClassName: SketchAttachContent
|
||||
* @Date 2016/5/19
|
||||
* @Description: ${TODO}(草图内容 )
|
||||
*/
|
||||
open class SketchAttachContent @JvmOverloads constructor(
|
||||
@PrimaryKey
|
||||
var id: String = "",
|
||||
/**
|
||||
* 获取geo
|
||||
*
|
||||
* @return geo
|
||||
*/
|
||||
/**
|
||||
* 设置geo
|
||||
*
|
||||
* @param geo geo
|
||||
*/
|
||||
//几何
|
||||
var geometry: String = "",
|
||||
/**
|
||||
* 获取style
|
||||
*
|
||||
* @return style
|
||||
*/
|
||||
/**
|
||||
* 设置style
|
||||
*
|
||||
* @param style style
|
||||
*/
|
||||
//样式
|
||||
var style: String = ""
|
||||
) : RealmObject()
|
||||
@@ -0,0 +1,3 @@
|
||||
package com.navinfo.collect.library.map
|
||||
|
||||
interface BaseClickListener
|
||||
@@ -1,20 +1,8 @@
|
||||
package com.navinfo.collect.library.map
|
||||
|
||||
import android.os.Build
|
||||
import androidx.annotation.RequiresApi
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import com.navinfo.collect.library.data.entity.NiLocation
|
||||
import com.navinfo.collect.library.data.handler.DataNiLocationHandler
|
||||
import com.navinfo.collect.library.map.NIMapView.OnMapClickListener
|
||||
import com.navinfo.collect.library.map.handler.*
|
||||
import com.navinfo.collect.library.map.handler.MeasureLayerHandler
|
||||
import com.navinfo.collect.library.map.handler.ViewportHandler
|
||||
import com.navinfo.collect.library.system.Constant
|
||||
import kotlinx.coroutines.flow.MutableSharedFlow
|
||||
import kotlinx.coroutines.flow.SharedFlow
|
||||
import kotlinx.coroutines.launch
|
||||
import org.oscim.core.GeoPoint
|
||||
|
||||
/**
|
||||
* 地图控制器
|
||||
@@ -31,7 +19,7 @@ class NIMapController {
|
||||
lateinit var viewportHandler: ViewportHandler
|
||||
lateinit var measureLayerHandler: MeasureLayerHandler
|
||||
|
||||
val onMapClickFlow = MutableSharedFlow<GeoPoint>()
|
||||
// val onMapClickFlow = MutableSharedFlow<GeoPoint>()
|
||||
|
||||
fun init(
|
||||
context: AppCompatActivity,
|
||||
@@ -45,23 +33,32 @@ class NIMapController {
|
||||
locationLayerHandler = LocationLayerHandler(context, mapView)
|
||||
animationHandler = AnimationHandler(context, mapView)
|
||||
markerHandle = MarkHandler(context, mapView)
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
|
||||
lineHandler = LineHandler(context, mapView)
|
||||
}
|
||||
lineHandler = LineHandler(context, mapView)
|
||||
polygonHandler = PolygonHandler(context, mapView)
|
||||
viewportHandler = ViewportHandler(context, mapView)
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
|
||||
measureLayerHandler = MeasureLayerHandler(context, mapView)
|
||||
}
|
||||
measureLayerHandler = MeasureLayerHandler(context, mapView)
|
||||
mMapView = mapView
|
||||
mMapView.setOnMapClickListener {
|
||||
context.lifecycleScope.launch {
|
||||
onMapClickFlow.emit(it)
|
||||
if (mapView.listenerTagList.isNotEmpty()) {
|
||||
val tag = mapView.listenerTagList.last()
|
||||
val listenerList = mapView.listenerList[tag]
|
||||
if (listenerList != null) {
|
||||
for (listener in listenerList) {
|
||||
if (listener is OnGeoPointClickListener) {
|
||||
listener.onMapClick(tag, it)
|
||||
return@setOnMapClickListener
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// context.lifecycleScope.launch {
|
||||
// onMapClickFlow.emit(it)
|
||||
// }
|
||||
|
||||
}
|
||||
mapView.setOptions(options)
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -3,8 +3,8 @@ package com.navinfo.collect.library.map;
|
||||
import android.content.Context;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.text.TextUtils;
|
||||
import android.util.AttributeSet;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
@@ -12,12 +12,12 @@ import android.view.ViewGroup;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.RelativeLayout;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.navinfo.collect.library.R;
|
||||
import com.navinfo.collect.library.data.entity.NiLocation;
|
||||
import com.navinfo.collect.library.map.layers.NaviMapScaleBar;
|
||||
import com.navinfo.collect.library.map.source.MapLifeNiLocationTileSource;
|
||||
|
||||
import org.oscim.android.MapPreferences;
|
||||
import org.oscim.android.MapView;
|
||||
@@ -29,21 +29,14 @@ import org.oscim.event.Gesture;
|
||||
import org.oscim.event.GestureListener;
|
||||
import org.oscim.layers.GroupLayer;
|
||||
import org.oscim.layers.Layer;
|
||||
import org.oscim.layers.tile.buildings.BuildingLayer;
|
||||
import org.oscim.layers.tile.vector.OsmTileLayer;
|
||||
import org.oscim.layers.tile.vector.VectorTileLayer;
|
||||
import org.oscim.layers.tile.vector.labeling.LabelLayer;
|
||||
import org.oscim.layers.tile.vector.labeling.LabelTileLoaderHook;
|
||||
import org.oscim.map.Map;
|
||||
import org.oscim.renderer.GLViewport;
|
||||
import org.oscim.theme.IRenderTheme;
|
||||
import org.oscim.theme.ThemeLoader;
|
||||
import org.oscim.scalebar.MapScaleBarLayer;
|
||||
import org.oscim.theme.VtmThemes;
|
||||
import org.oscim.tiling.source.mapfile.MapFileTileSource;
|
||||
import org.oscim.tiling.source.mapfile.MultiMapFileTileSource;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -90,11 +83,6 @@ public final class NIMapView extends RelativeLayout {
|
||||
* 地图状态设置
|
||||
*/
|
||||
private NIMapOptions options;
|
||||
/**
|
||||
* 地图图层管理器
|
||||
*/
|
||||
// private NILayerManager mLayerManager;
|
||||
// private Layer baseRasterLayer, defaultVectorTileLayer, defaultVectorLabelLayer, gridLayer;
|
||||
/**
|
||||
* 地图网格图层
|
||||
*/
|
||||
@@ -108,6 +96,23 @@ public final class NIMapView extends RelativeLayout {
|
||||
protected String mapFilePath = "/map";
|
||||
protected GroupLayer baseGroupLayer; // 用于盛放所有基础底图的图层组,便于统一管理
|
||||
|
||||
|
||||
private HashMap<String, BaseClickListener[]> listenerList = new HashMap();
|
||||
private List<String> listenerTagList = new ArrayList();
|
||||
|
||||
public HashMap<String, BaseClickListener[]> getListenerList() {
|
||||
return listenerList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取所有tag
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public List<String> getListenerTagList() {
|
||||
return listenerTagList;
|
||||
}
|
||||
|
||||
public void setOptions(NIMapOptions option) {
|
||||
this.options = option;
|
||||
initOptions();
|
||||
@@ -172,11 +177,11 @@ public final class NIMapView extends RelativeLayout {
|
||||
}
|
||||
|
||||
|
||||
// public NIMapView(Context context, NIMapOptions options) {
|
||||
// this(context, null, 0);
|
||||
// this.options = options;
|
||||
// initOptions();
|
||||
// }
|
||||
/* public NIMapView(Context context, NIMapOptions options) {
|
||||
this(context, null, 0);
|
||||
this.options = options;
|
||||
initOptions();
|
||||
}*/
|
||||
|
||||
/**
|
||||
* 地图的单击事件监听
|
||||
@@ -198,6 +203,11 @@ public final class NIMapView extends RelativeLayout {
|
||||
*/
|
||||
private OnMapTouchListener touchListener;
|
||||
|
||||
/**
|
||||
* 比例尺控件
|
||||
*/
|
||||
private MapScaleBarLayer mapScaleBarLayer;
|
||||
|
||||
public NIMapView(Context context, AttributeSet attrs) {
|
||||
this(context, attrs, 0);
|
||||
}
|
||||
@@ -252,7 +262,7 @@ public final class NIMapView extends RelativeLayout {
|
||||
|
||||
// 增加比例尺图层
|
||||
NaviMapScaleBar naviMapScaleBar = new NaviMapScaleBar(getVtmMap());
|
||||
naviMapScaleBar.initScaleBarLayer(GLViewport.Position.BOTTOM_CENTER, 128, 5);
|
||||
mapScaleBarLayer = naviMapScaleBar.initScaleBarLayer(GLViewport.Position.BOTTOM_CENTER, 128, 5);
|
||||
|
||||
// if (gridLayer == null) {
|
||||
// gridLayer = new TileGridLayer(getVtmMap());
|
||||
@@ -806,8 +816,6 @@ public final class NIMapView extends RelativeLayout {
|
||||
|
||||
/**
|
||||
* 设置logo显隐
|
||||
*
|
||||
* @param position 按钮位置
|
||||
*/
|
||||
public void setLogoVisable(int visable) {
|
||||
if (logoImage != null) {
|
||||
@@ -878,6 +886,22 @@ public final class NIMapView extends RelativeLayout {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置比例尺位置
|
||||
*
|
||||
* @param position
|
||||
* @param xOffset
|
||||
* @param yOffset
|
||||
*/
|
||||
public void setScaleBarLayer(GLViewport.Position position, int xOffset, int yOffset) {
|
||||
if (mapScaleBarLayer != null && mapView.map().layers().contains(mapScaleBarLayer)) {
|
||||
mapView.map().layers().remove(mapScaleBarLayer);
|
||||
mapScaleBarLayer = null;
|
||||
}
|
||||
NaviMapScaleBar naviMapScaleBar = new NaviMapScaleBar(getVtmMap());
|
||||
mapScaleBarLayer = naviMapScaleBar.initScaleBarLayer(GLViewport.Position.BOTTOM_CENTER, xOffset, yOffset);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置是否显示缩放控件
|
||||
*
|
||||
@@ -1008,4 +1032,39 @@ public final class NIMapView extends RelativeLayout {
|
||||
mapView.map().updateMap(redraw);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 增加地图点击监听
|
||||
*/
|
||||
public boolean addOnNIMapClickListener(@NonNull String tag, @NonNull BaseClickListener... listeners) {
|
||||
if (TextUtils.equals(tag, "")) {
|
||||
return false;
|
||||
}
|
||||
for (Object s : listenerTagList) {
|
||||
if (s == tag) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
listenerTagList.add(tag);
|
||||
listenerList.put(tag, listeners);
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* 移除点击监听
|
||||
*
|
||||
* @param tag
|
||||
*/
|
||||
public void removeOnNIMapClickListener(@NonNull String tag) {
|
||||
listenerList.remove(tag);
|
||||
for (String t : listenerTagList) {
|
||||
if (t.equals(tag)) {
|
||||
listenerTagList.remove(t);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
package com.navinfo.collect.library.map
|
||||
|
||||
import org.oscim.core.GeoPoint
|
||||
|
||||
interface OnGeoPointClickListener : BaseClickListener {
|
||||
fun onMapClick(tag: String, point: GeoPoint)
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.navinfo.collect.library.map.handler
|
||||
|
||||
import android.content.Context
|
||||
import android.util.Log
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import org.oscim.layers.Layer
|
||||
@@ -10,6 +10,7 @@ abstract class BaseHandler(context: AppCompatActivity, mapView: NIMapView) {
|
||||
protected val mMapView: NIMapView = mapView
|
||||
|
||||
fun addLayer(layer: Layer, groupType: NIMapView.LAYER_GROUPS) {
|
||||
Log.e("jingo", "增加了图层 ${layer.toString()}")
|
||||
mMapView.vtmMap.layers().add(
|
||||
layer,
|
||||
groupType.groupIndex
|
||||
@@ -17,9 +18,11 @@ abstract class BaseHandler(context: AppCompatActivity, mapView: NIMapView) {
|
||||
}
|
||||
|
||||
fun removeLayer(layer: Layer) {
|
||||
Log.e("jingo", "移除了图层 ${layer.toString()}")
|
||||
mMapView.vtmMap.layers().remove(layer)
|
||||
}
|
||||
|
||||
|
||||
// fun setOnMapClickListener(listener: NIMapView.OnMapClickListener) {
|
||||
// mMapView.setOnMapClickListener(listener)
|
||||
// }
|
||||
|
||||
@@ -217,6 +217,13 @@ class LayerManagerHandler(context: AppCompatActivity, mapView: NIMapView, traceP
|
||||
vectorNiLocationTileLayer.isEnabled = false
|
||||
labelNiLocationLayer.isEnabled = false
|
||||
}
|
||||
|
||||
fun omdbLayersUpdate(){
|
||||
// omdbVectorTileLayer
|
||||
// omdbReferenceTileLayer.
|
||||
omdbLabelLayer.update()
|
||||
omdbReferenceLabelLayer.update()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,176 +1,121 @@
|
||||
package com.navinfo.collect.library.map.handler
|
||||
|
||||
import android.graphics.BitmapFactory
|
||||
import android.os.Build
|
||||
import android.widget.Toast
|
||||
import androidx.annotation.RequiresApi
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import com.navinfo.collect.library.R
|
||||
import com.navinfo.collect.library.data.entity.HadLinkDvoBean
|
||||
import com.navinfo.collect.library.map.BaseClickListener
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import com.navinfo.collect.library.map.layers.MultiLinesLayer
|
||||
import com.navinfo.collect.library.map.layers.OmdbTaskLinkLayer
|
||||
import com.navinfo.collect.library.utils.GeometryTools
|
||||
import com.navinfo.collect.library.utils.StringUtil
|
||||
import org.locationtech.jts.geom.LineString
|
||||
import org.oscim.android.canvas.AndroidBitmap
|
||||
import org.oscim.backend.canvas.Bitmap
|
||||
import org.oscim.core.GeoPoint
|
||||
import org.oscim.core.MapPosition
|
||||
import org.oscim.event.Event
|
||||
import org.oscim.layers.marker.ItemizedLayer
|
||||
import org.oscim.layers.marker.ItemizedLayer.OnItemGestureListener
|
||||
import org.oscim.layers.marker.MarkerInterface
|
||||
import org.oscim.layers.marker.MarkerItem
|
||||
import org.oscim.layers.marker.MarkerSymbol
|
||||
import org.oscim.layers.vector.PathLayer
|
||||
import org.oscim.layers.vector.VectorLayer
|
||||
import org.oscim.layers.vector.geometries.Style
|
||||
import org.oscim.map.Map
|
||||
|
||||
@RequiresApi(Build.VERSION_CODES.M)
|
||||
class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(context, mapView),
|
||||
Map.UpdateListener {
|
||||
|
||||
private var editIndex: Int = -1;
|
||||
private val mPathMakers: MutableList<MarkerItem> = mutableListOf()
|
||||
|
||||
//绘制线 引导线样式
|
||||
private val newTempStyle: Style
|
||||
|
||||
//绘制线 样式
|
||||
private val lineStyle: Style
|
||||
|
||||
//高亮线绘制线 样式
|
||||
private val defaultLineStyle: Style
|
||||
|
||||
//线型编辑时的样式
|
||||
private val editTempStyle: Style
|
||||
|
||||
//新增线数据
|
||||
private val mPathLayer: PathLayer
|
||||
|
||||
//新增线数据引线
|
||||
private val mPathLayerTemp: PathLayer
|
||||
|
||||
//线路端点图标
|
||||
private val mPathMarkerBitmap: Bitmap
|
||||
|
||||
//线路端点marker
|
||||
private val mEndpointLayer: ItemizedLayer
|
||||
|
||||
private var bDrawLine = false
|
||||
class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(context, mapView) {
|
||||
|
||||
|
||||
private val mDefaultPathLayer: PathLayer
|
||||
/**
|
||||
* 高亮线图层,同时只高亮一条线,如线选择
|
||||
*/
|
||||
private val mDefaultPathLayer: PathLayer by lazy {
|
||||
//高亮线绘制线 样式
|
||||
val defaultLineStyle = Style.builder()
|
||||
.stippleColor(context.resources.getColor(R.color.draw_line_blue2_color))
|
||||
.strokeWidth(10f)
|
||||
.fillColor(context.resources.getColor(R.color.teal_200))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.teal_200))
|
||||
.fixed(true).build()
|
||||
|
||||
val layer = PathLayer(mMapView.vtmMap, defaultLineStyle)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
layer
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 路口高亮
|
||||
*/
|
||||
val linksLayer by lazy {
|
||||
val layer = MultiLinesLayer(mapView.vtmMap)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
layer
|
||||
}
|
||||
|
||||
val omdbTaskLinkLayer by lazy {
|
||||
val omdbTaskLinkLayer = OmdbTaskLinkLayer(
|
||||
/**
|
||||
* 任务线图层
|
||||
*/
|
||||
private val omdbTaskLinkLayer: OmdbTaskLinkLayer by lazy {
|
||||
val layer = 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))
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_red_color))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color))
|
||||
.strokeWidth(8f)
|
||||
.fixed(true).build()
|
||||
)
|
||||
addLayer(omdbTaskLinkLayer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
omdbTaskLinkLayer
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
layer
|
||||
}
|
||||
|
||||
init {
|
||||
mMapView.vtmMap.events.bind(this)
|
||||
/**
|
||||
* 任务线的marker,新增link会有marker
|
||||
*/
|
||||
private val omdbTaskMarkerLayer: ItemizedLayer by lazy {
|
||||
|
||||
//新增线数据图层和线样式
|
||||
lineStyle = Style.builder()
|
||||
.stippleColor(context.resources.getColor(R.color.draw_line_blue1_color, null))
|
||||
.strokeWidth(4f)
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fillAlpha(0.5f)
|
||||
.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)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fixed(true).randomOffset(false).build()
|
||||
|
||||
editTempStyle =
|
||||
Style.builder().stippleColor(context.resources.getColor(R.color.transparent, null))
|
||||
.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, defaultLineStyle)
|
||||
addLayer(mDefaultPathLayer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
mPathLayer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
// addLayer(mPathLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
|
||||
mPathLayerTemp = PathLayer(mMapView.vtmMap, newTempStyle)
|
||||
// addLayer(mPathLayerTemp, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
|
||||
mPathMarkerBitmap = AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
mContext.resources, R.mipmap.icon_path_maker
|
||||
//新增marker图标样式
|
||||
val mDefaultBitmap =
|
||||
AndroidBitmap(
|
||||
context.resources.openRawResource(R.raw.icon_task_link_marker), 48, 48, 100
|
||||
)
|
||||
val markerSymbol = MarkerSymbol(
|
||||
mDefaultBitmap,
|
||||
MarkerSymbol.HotspotPlace.CENTER
|
||||
)
|
||||
val markerSymbol = MarkerSymbol(mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
//新增marker图层
|
||||
mEndpointLayer = ItemizedLayer(
|
||||
mMapView.vtmMap, ArrayList<MarkerInterface>(), markerSymbol, null
|
||||
)
|
||||
// addLayer(mEndpointLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
mEndpointLayer.setOnItemGestureListener(object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface): Boolean {
|
||||
if (bDrawLine) {
|
||||
for (i in mPathMakers.indices) {
|
||||
val item1 = mPathMakers[i]
|
||||
if (item === item1) {
|
||||
mMapView.vtmMap.animator().animateTo(
|
||||
GeoPoint(
|
||||
item.getPoint().latitude, item.getPoint().longitude
|
||||
)
|
||||
)
|
||||
editIndex = i
|
||||
mPathLayerTemp.setStyle(editTempStyle)
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
if (editIndex == 0 || editIndex == mPathMakers.size - 1) {
|
||||
list.add(item.getPoint())
|
||||
list.add(item.getPoint())
|
||||
} else {
|
||||
list.add(mPathMakers[editIndex - 1].geoPoint)
|
||||
list.add(item.getPoint())
|
||||
list.add(mPathMakers[editIndex + 1].geoPoint)
|
||||
val layer = ItemizedLayer(
|
||||
mapView.vtmMap,
|
||||
ArrayList(),
|
||||
markerSymbol,
|
||||
object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface?): Boolean {
|
||||
val tag = mMapView.listenerTagList.last()
|
||||
val listenerList = mMapView.listenerList[tag]
|
||||
if (listenerList != null) {
|
||||
for (listener in listenerList) {
|
||||
if (listener is OnTaskLinkItemClickListener) {
|
||||
if (item is MarkerItem) {
|
||||
listener.onTaskLink(tag, item.title)
|
||||
}
|
||||
break
|
||||
}
|
||||
mPathLayerTemp.setPoints(list)
|
||||
return false
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
override fun onItemLongPress(index: Int, item: MarkerInterface?): Boolean {
|
||||
return false
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
override fun onItemLongPress(index: Int, item: MarkerInterface): Boolean {
|
||||
return false
|
||||
}
|
||||
})
|
||||
)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 高亮一条线
|
||||
*/
|
||||
fun showLine(geometry: String) {
|
||||
try {
|
||||
mDefaultPathLayer.clearPath()
|
||||
@@ -181,218 +126,91 @@ class LineHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 取消高亮线
|
||||
*/
|
||||
fun removeLine() {
|
||||
mDefaultPathLayer.clearPath()
|
||||
mDefaultPathLayer.isEnabled = false
|
||||
}
|
||||
|
||||
fun addDrawLinePoint(geoPoint: GeoPoint): List<GeoPoint> {
|
||||
|
||||
if (!bDrawLine) {
|
||||
mPathLayer.isEnabled = true
|
||||
mPathLayerTemp.isEnabled = true
|
||||
mEndpointLayer.isEnabled = true
|
||||
bDrawLine = true
|
||||
}
|
||||
//编辑点
|
||||
if (editIndex > -1) {
|
||||
if (mPathLayer.points.size > 0) {
|
||||
var list: MutableList<GeoPoint> = mutableListOf<GeoPoint>()
|
||||
list.addAll(mPathLayer.points)
|
||||
if (list.size > 3) {
|
||||
if (editIndex == 0) {
|
||||
val listNew = mutableListOf<GeoPoint>()
|
||||
listNew.add(geoPoint)
|
||||
listNew.add(list[1])
|
||||
list.removeAt(0)
|
||||
if (GeometryTools.isLineStringCrosses(list, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
} else if (editIndex == list.size - 1) {
|
||||
val listNew = mutableListOf<GeoPoint>()
|
||||
listNew.add(geoPoint)
|
||||
listNew.add(list[editIndex - 1])
|
||||
list.removeAt(editIndex)
|
||||
if (GeometryTools.isLineStringCrosses(list, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
} else if (editIndex == 1) {
|
||||
val listNew = mutableListOf<GeoPoint>()
|
||||
listNew.add(list[0])
|
||||
listNew.add(geoPoint)
|
||||
listNew.add(list[2])
|
||||
list = list.subList(2, list.size)
|
||||
if (GeometryTools.isLineStringCrosses(list, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
} else if (editIndex == list.size - 2) {
|
||||
val listNew = mutableListOf<GeoPoint>()
|
||||
listNew.add(list[list.size - 1])
|
||||
listNew.add(geoPoint)
|
||||
listNew.add(list[editIndex - 1])
|
||||
list = list.subList(0, list.size - 2)
|
||||
if (GeometryTools.isLineStringCrosses(list, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
} else {
|
||||
val listNew = mutableListOf<GeoPoint>()
|
||||
listNew.add(list[editIndex - 1])
|
||||
listNew.add(geoPoint)
|
||||
listNew.add(list[editIndex + 1])
|
||||
val list1: MutableList<GeoPoint> = mutableListOf();
|
||||
list1.addAll(list.subList(0, editIndex))
|
||||
val list2: MutableList<GeoPoint> = mutableListOf()
|
||||
list2.addAll(list.subList(editIndex + 1, list.size))
|
||||
if (GeometryTools.isLineStringCrosses(list1, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
if (GeometryTools.isLineStringCrosses(list2, listNew)) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
}
|
||||
}
|
||||
if (editIndex < mPathLayer.points.size) {
|
||||
mPathLayer.points.removeAt(editIndex)
|
||||
val list2: MutableList<GeoPoint> = mutableListOf<GeoPoint>()
|
||||
list2.addAll(mPathLayer.points)
|
||||
list2.add(editIndex, geoPoint)
|
||||
mPathLayer.setPoints(list2)
|
||||
}
|
||||
}
|
||||
if (mPathMakers.size > editIndex) {
|
||||
mEndpointLayer.removeItem(mPathMakers[editIndex])
|
||||
mPathMakers.removeAt(editIndex)
|
||||
val markerItem = MarkerItem(StringUtil.createUUID(), "", "", geoPoint)
|
||||
mEndpointLayer.addItem(markerItem)
|
||||
mPathMakers.add(editIndex, markerItem)
|
||||
mPathLayerTemp.setStyle(newTempStyle)
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
// if (NMPFragmentManager.getInstance()
|
||||
// .getNewDataBottomType() === 3 && mPathMakers.size > 1
|
||||
// ) {
|
||||
// list.add(mPathMakers[0].geoPoint)
|
||||
// list.add(geoPoint)
|
||||
// list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
// } else {
|
||||
list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
list.add(geoPoint)
|
||||
// }
|
||||
mPathLayerTemp.setPoints(list)
|
||||
}
|
||||
editIndex = -1
|
||||
} else { //新增点
|
||||
val points: List<GeoPoint> = mPathLayer.points
|
||||
if (points.size > 2) {
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
list.add(geoPoint)
|
||||
list.add(points[points.size - 1])
|
||||
val bCross = GeometryTools.isLineStringCrosses(points, list)
|
||||
if (bCross) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return mPathLayer.points
|
||||
}
|
||||
}
|
||||
mPathLayer.addPoint(geoPoint)
|
||||
val markerItem = MarkerItem(StringUtil.createUUID(), "", "", geoPoint)
|
||||
mEndpointLayer.addItem(markerItem)
|
||||
mPathMakers.add(markerItem)
|
||||
}
|
||||
|
||||
return mPathLayer.points
|
||||
}
|
||||
|
||||
fun addDrawLine(list: List<GeoPoint>) {
|
||||
for (item in list) {
|
||||
addDrawLinePoint(item)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
override fun onMapEvent(e: Event, mapPosition: MapPosition) {
|
||||
if (!bDrawLine) return
|
||||
// if (mMapView.centerPixel[1] > mMapView.vtmMap.height / 2) {
|
||||
// val geoPoint =
|
||||
// mMapView.vtmMap.viewport()
|
||||
// .fromScreenPoint(
|
||||
// mMapView.centerPixel[0],
|
||||
// mMapView.vtmMap.height - mMapView.centerPixel[1]
|
||||
// )
|
||||
// mapPosition.setPosition(geoPoint)
|
||||
// }
|
||||
if (e === Map.POSITION_EVENT) {
|
||||
if (mPathLayer.points.size > 0) {
|
||||
if (editIndex > -1) {
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
if (editIndex == 0 || editIndex == mPathMakers.size - 1) {
|
||||
list.add(mPathMakers[editIndex].geoPoint)
|
||||
list.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
} else {
|
||||
list.add(mPathMakers[editIndex - 1].geoPoint)
|
||||
list.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
list.add(mPathMakers[editIndex + 1].geoPoint)
|
||||
}
|
||||
mPathLayerTemp.setPoints(list)
|
||||
// crossText.setText("")
|
||||
} else {
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
list.add(mPathLayer.points[mPathLayer.points.size - 1])
|
||||
list.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
mPathLayerTemp.setPoints(list)
|
||||
if (mPathLayer.points.size > 0) {
|
||||
val listDis: MutableList<GeoPoint> = mutableListOf()
|
||||
listDis.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
// val distance: Double =
|
||||
// GeometryTools.getDistance(listDis)
|
||||
// if (distance < 1000) crossText.setText(
|
||||
// distance as Int.toString() + "米"
|
||||
// ) else {
|
||||
// val d = distance / 1000.0
|
||||
// val bg = BigDecimal(d)
|
||||
// val f1 =
|
||||
// bg.setScale(1, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
//// crossText.setText(f1.toString() + "公里")
|
||||
// }
|
||||
} else {
|
||||
// crossText.setText("")
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun clear() {
|
||||
mPathLayer.clearPath()
|
||||
mPathLayer.isEnabled = false
|
||||
mPathLayerTemp.clearPath()
|
||||
mPathLayerTemp.isEnabled = false
|
||||
mEndpointLayer.removeAllItems()
|
||||
mEndpointLayer.isEnabled = false
|
||||
mPathMakers.clear()
|
||||
editIndex = -1
|
||||
bDrawLine = false
|
||||
/**
|
||||
* 移除所有任务高亮线
|
||||
*/
|
||||
fun removeAllTaskLine() {
|
||||
omdbTaskLinkLayer.removeAll()
|
||||
linksLayer.clear()
|
||||
omdbTaskMarkerLayer.removeAllItems()
|
||||
}
|
||||
|
||||
/**
|
||||
* 显示所有任务高亮线
|
||||
*/
|
||||
fun showTaskLines(hadLinkDvoList: List<HadLinkDvoBean>) {
|
||||
for (link in hadLinkDvoList) {
|
||||
if (link.linkStatus == 3) {
|
||||
val pointList = GeometryTools.getGeoPoints(link.geometry)
|
||||
val geoPoint = if (pointList.size < 3) {
|
||||
pointList[0]
|
||||
} else {
|
||||
pointList[1]
|
||||
}
|
||||
val marker = MarkerItem(
|
||||
link.linkPid,
|
||||
"",
|
||||
geoPoint
|
||||
)
|
||||
omdbTaskMarkerLayer.addItem(marker)
|
||||
}
|
||||
}
|
||||
omdbTaskLinkLayer.addLineList(hadLinkDvoList)
|
||||
}
|
||||
|
||||
/**
|
||||
* 增加一条任务高亮线
|
||||
*/
|
||||
fun addTaskLink(linkBean: HadLinkDvoBean) {
|
||||
for (marker in omdbTaskMarkerLayer.itemList) {
|
||||
if ((marker as MarkerItem).title == linkBean.linkPid) {
|
||||
omdbTaskMarkerLayer.removeItem(marker)
|
||||
break
|
||||
}
|
||||
}
|
||||
if (linkBean.linkStatus == 3) {
|
||||
val pointList = GeometryTools.getGeoPoints(linkBean.geometry)
|
||||
val geoPoint = if (pointList.size < 3) {
|
||||
pointList[0]
|
||||
} else {
|
||||
pointList[1]
|
||||
}
|
||||
val marker = MarkerItem(
|
||||
linkBean.linkPid,
|
||||
"",
|
||||
geoPoint
|
||||
)
|
||||
omdbTaskMarkerLayer.addItem(marker)
|
||||
}
|
||||
omdbTaskLinkLayer.removeLine(linkBean.linkPid)
|
||||
omdbTaskLinkLayer.addLine(linkBean)
|
||||
omdbTaskLinkLayer.update()
|
||||
mMapView.vtmMap.updateMap(true)
|
||||
}
|
||||
|
||||
/**
|
||||
* 增加一条任务高亮线
|
||||
*/
|
||||
fun removeTaskLink(linkBeanId: String) {
|
||||
for (marker in omdbTaskMarkerLayer.itemList) {
|
||||
if ((marker as MarkerItem).title == linkBeanId) {
|
||||
omdbTaskMarkerLayer.removeItem(marker)
|
||||
break
|
||||
}
|
||||
}
|
||||
omdbTaskLinkLayer.removeLine(linkBeanId)
|
||||
omdbTaskLinkLayer.update()
|
||||
mMapView.vtmMap.updateMap(true)
|
||||
}
|
||||
}
|
||||
|
||||
interface OnTaskLinkItemClickListener : BaseClickListener {
|
||||
fun onTaskLink(tag: String, taskLinkId: String)
|
||||
}
|
||||
@@ -12,6 +12,7 @@ import com.baidu.location.LocationClientOption.LocationMode
|
||||
import com.navinfo.collect.library.data.entity.NiLocation
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import com.navinfo.collect.library.utils.DateUtils
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.flow.MutableSharedFlow
|
||||
import kotlinx.coroutines.launch
|
||||
import org.oscim.core.GeoPoint
|
||||
@@ -66,18 +67,12 @@ class LocationLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
val errorCode = it.locType
|
||||
mCurrentLocation = it
|
||||
mLocationLayer.setPosition(it.latitude, it.longitude, it.radius)
|
||||
// Log.e(
|
||||
// "qj",
|
||||
// "location==${it.longitude}==errorCode===$errorCode===${it.locTypeDescription}"
|
||||
// )
|
||||
Log.e("qj", "location==${it.longitude}==errorCode===$errorCode===${it.locTypeDescription}")
|
||||
|
||||
// if (niLocationListener != null) {
|
||||
getCurrentNiLocation()?.let { it1 ->
|
||||
mContext.lifecycleScope.launch {
|
||||
niLocationFlow.emit(it1)
|
||||
}
|
||||
|
||||
// }// niLocationListener.call(it1) }
|
||||
getCurrentNiLocation()?.let { it1 ->
|
||||
mContext.lifecycleScope.launch {
|
||||
niLocationFlow.emit(it1)
|
||||
}
|
||||
}
|
||||
//第一次定位成功显示当前位置
|
||||
if (this.bFirst) {
|
||||
|
||||
@@ -4,24 +4,23 @@ import android.content.Context
|
||||
import android.graphics.BitmapFactory
|
||||
import android.graphics.Canvas
|
||||
import android.graphics.Color
|
||||
import android.util.Log
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.core.content.res.ResourcesCompat
|
||||
import androidx.lifecycle.lifecycleScope
|
||||
import com.navinfo.collect.library.R
|
||||
import com.navinfo.collect.library.data.entity.NiLocation
|
||||
import com.navinfo.collect.library.data.entity.NoteBean
|
||||
import com.navinfo.collect.library.data.entity.QsRecordBean
|
||||
import com.navinfo.collect.library.map.BaseClickListener
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import com.navinfo.collect.library.map.cluster.ClusterMarkerItem
|
||||
import com.navinfo.collect.library.map.cluster.ClusterMarkerRenderer
|
||||
import com.navinfo.collect.library.map.layers.MyItemizedLayer
|
||||
import com.navinfo.collect.library.map.layers.NoteLineLayer
|
||||
import com.navinfo.collect.library.utils.GeometryTools
|
||||
import com.navinfo.collect.library.utils.StringUtil
|
||||
import io.realm.Realm
|
||||
import io.realm.kotlin.where
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.launch
|
||||
import kotlinx.coroutines.withContext
|
||||
import org.locationtech.jts.geom.Geometry
|
||||
import org.locationtech.jts.geom.LineString
|
||||
import org.locationtech.jts.geom.Polygon
|
||||
import org.oscim.android.canvas.AndroidBitmap
|
||||
import org.oscim.backend.CanvasAdapter
|
||||
import org.oscim.backend.canvas.Bitmap
|
||||
@@ -29,9 +28,9 @@ import org.oscim.backend.canvas.Paint
|
||||
import org.oscim.core.GeoPoint
|
||||
import org.oscim.layers.marker.*
|
||||
import org.oscim.layers.marker.ItemizedLayer.OnItemGestureListener
|
||||
import org.oscim.layers.vector.geometries.*
|
||||
import org.oscim.map.Map
|
||||
import java.util.*
|
||||
import kotlin.collections.ArrayList
|
||||
|
||||
/**
|
||||
* marker 操作
|
||||
@@ -39,9 +38,6 @@ import kotlin.collections.ArrayList
|
||||
class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
BaseHandler(context, mapView) {
|
||||
|
||||
// //默认marker图层
|
||||
private var mDefaultMarkerLayer: ItemizedLayer
|
||||
|
||||
/**
|
||||
* 默认文字颜色
|
||||
*/
|
||||
@@ -50,68 +46,250 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
/**
|
||||
* 文字画笔
|
||||
*/
|
||||
private val paint: Paint by lazy {
|
||||
val p = CanvasAdapter.newPaint()
|
||||
p.setTypeface(Paint.FontFamily.DEFAULT, Paint.FontStyle.NORMAL)
|
||||
p.setTextSize(NUM_13 * CanvasAdapter.getScale())
|
||||
p.strokeWidth = 2 * CanvasAdapter.getScale()
|
||||
p.color = Color.parseColor(mDefaultTextColor)
|
||||
p
|
||||
}
|
||||
|
||||
private lateinit var paint: Paint
|
||||
/**
|
||||
* 画布
|
||||
*/
|
||||
private val canvas: org.oscim.backend.canvas.Canvas = CanvasAdapter.newCanvas()
|
||||
|
||||
//画布
|
||||
private lateinit var canvas: org.oscim.backend.canvas.Canvas
|
||||
private lateinit var itemizedLayer: MyItemizedLayer
|
||||
private lateinit var markerRendererFactory: MarkerRendererFactory
|
||||
private var resId = R.mipmap.map_icon_report
|
||||
private var itemListener: OnQsRecordItemClickListener? = null
|
||||
/**
|
||||
* 默认marker图层
|
||||
*/
|
||||
private val mDefaultMarkerLayer: ItemizedLayer by lazy {
|
||||
//新增marker图标样式
|
||||
val mDefaultBitmap =
|
||||
AndroidBitmap(BitmapFactory.decodeResource(context.resources, R.mipmap.marker))
|
||||
|
||||
val markerSymbol = MarkerSymbol(
|
||||
mDefaultBitmap,
|
||||
MarkerSymbol.HotspotPlace.CENTER
|
||||
)
|
||||
val layer = ItemizedLayer(
|
||||
mapView.vtmMap,
|
||||
markerSymbol,
|
||||
)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
private val niLocationBitmap: Bitmap by lazy {
|
||||
AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources,
|
||||
R.mipmap.icon_gps
|
||||
)
|
||||
)
|
||||
}
|
||||
private val niLocationBitmap1: Bitmap by lazy {
|
||||
AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources,
|
||||
R.mipmap.icon_gps_1
|
||||
)
|
||||
)
|
||||
}
|
||||
private val niLocationBitmap2: Bitmap by lazy {
|
||||
AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources,
|
||||
R.mipmap.icon_nilocation
|
||||
)
|
||||
)
|
||||
}
|
||||
private val niLocationBitmap3: Bitmap by lazy {
|
||||
AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources,
|
||||
R.mipmap.icon_nilocation_1
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
/**
|
||||
* 评测数据marker 图层
|
||||
*/
|
||||
private val qsRecordItemizedLayer: MyItemizedLayer by lazy {
|
||||
val bitmapPoi: Bitmap = AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
mContext.resources,
|
||||
R.mipmap.map_icon_blue2
|
||||
)
|
||||
)
|
||||
val symbol = MarkerSymbol(bitmapPoi, MarkerSymbol.HotspotPlace.BOTTOM_CENTER)
|
||||
val markerRendererFactory = MarkerRendererFactory { markerLayer ->
|
||||
object : ClusterMarkerRenderer(
|
||||
mContext,
|
||||
markerLayer,
|
||||
symbol,
|
||||
ClusterStyle(
|
||||
org.oscim.backend.canvas.Color.WHITE,
|
||||
org.oscim.backend.canvas.Color.BLUE
|
||||
)
|
||||
) {
|
||||
}
|
||||
}
|
||||
val layer = MyItemizedLayer(
|
||||
mMapView.vtmMap,
|
||||
mutableListOf(),
|
||||
markerRendererFactory,
|
||||
object : MyItemizedLayer.OnItemGestureListener {
|
||||
override fun onItemSingleTapUp(
|
||||
list: MutableList<Int>,
|
||||
nearest: Int
|
||||
): Boolean {
|
||||
val tag = mMapView.listenerTagList.last()
|
||||
val listenerList = mMapView.listenerList[tag]
|
||||
if (listenerList != null) {
|
||||
for (listener in listenerList) {
|
||||
if (listener is OnQsRecordItemClickListener) {
|
||||
val idList = mutableListOf<String>()
|
||||
for (i in list) {
|
||||
val markerInterface: MarkerInterface =
|
||||
qsRecordItemizedLayer.itemList[i]
|
||||
if (markerInterface is MarkerItem) {
|
||||
idList.add(markerInterface.title)
|
||||
}
|
||||
}
|
||||
listener.onQsRecordList(tag, idList.distinct().toMutableList())
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun onItemLongPress(
|
||||
list: MutableList<Int>?,
|
||||
nearest: Int
|
||||
): Boolean {
|
||||
return true
|
||||
}
|
||||
})
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
/**
|
||||
* 评测数据marker 图层
|
||||
*/
|
||||
private val niLocationItemizedLayer: ItemizedLayer by lazy {
|
||||
|
||||
val symbol = MarkerSymbol(niLocationBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
val layer = ItemizedLayer(
|
||||
mapView.vtmMap,
|
||||
symbol,
|
||||
)
|
||||
layer.setOnItemGestureListener(object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface?): Boolean {
|
||||
val tag = mMapView.listenerTagList.last()
|
||||
val listenerList = mMapView.listenerList[tag]
|
||||
if (listenerList != null) {
|
||||
for (listener in listenerList) {
|
||||
if (listener is OnNiLocationItemListener) {
|
||||
listener.onNiLocation(
|
||||
tag,
|
||||
index,
|
||||
(niLocationItemizedLayer.itemList[index] as MarkerItem).uid as NiLocation
|
||||
)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun onItemLongPress(index: Int, item: MarkerInterface?): Boolean {
|
||||
return true
|
||||
}
|
||||
|
||||
})
|
||||
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
/**
|
||||
* 便签线图层
|
||||
*/
|
||||
private val noteLineLayer: NoteLineLayer by lazy {
|
||||
val layer = NoteLineLayer(mMapView.vtmMap)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.VECTOR)
|
||||
layer
|
||||
}
|
||||
|
||||
/**
|
||||
* 便签图标图层
|
||||
*/
|
||||
private val noteLayer: ItemizedLayer by lazy {
|
||||
val bitmap =
|
||||
AndroidBitmap(BitmapFactory.decodeResource(context.resources, noteResId))
|
||||
val symbol = MarkerSymbol(bitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
val layer = ItemizedLayer(
|
||||
mMapView.vtmMap,
|
||||
symbol,
|
||||
)
|
||||
layer.setOnItemGestureListener(object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface?): Boolean {
|
||||
val tag = mMapView.listenerTagList.last()
|
||||
val listenerList = mMapView.listenerList[tag]
|
||||
if (listenerList != null) {
|
||||
for (listener in listenerList) {
|
||||
if (listener is ONNoteItemClickListener) {
|
||||
val marker = layer.itemList[index]
|
||||
if (marker is MarkerItem)
|
||||
listener.onNote(tag, marker.title)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun onItemLongPress(index: Int, item: MarkerInterface?): Boolean {
|
||||
return true
|
||||
}
|
||||
})
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
|
||||
private val resId = R.mipmap.map_icon_report
|
||||
private val noteResId = R.drawable.icon_note_marker
|
||||
|
||||
/**
|
||||
* 文字大小
|
||||
*/
|
||||
private val NUM_13 = 13
|
||||
|
||||
|
||||
init {
|
||||
//新增marker图标样式
|
||||
val mDefaultBitmap =
|
||||
AndroidBitmap(BitmapFactory.decodeResource(context.resources, R.mipmap.marker));
|
||||
|
||||
val markerSymbol = MarkerSymbol(
|
||||
mDefaultBitmap,
|
||||
MarkerSymbol.HotspotPlace.BOTTOM_CENTER
|
||||
);
|
||||
//新增marker图层
|
||||
mDefaultMarkerLayer = ItemizedLayer(
|
||||
mapView.vtmMap,
|
||||
ArrayList<MarkerInterface>(),
|
||||
markerSymbol,
|
||||
object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface?): Boolean {
|
||||
return false
|
||||
}
|
||||
|
||||
override fun onItemLongPress(index: Int, item: MarkerInterface?): Boolean {
|
||||
return false
|
||||
}
|
||||
|
||||
}
|
||||
)
|
||||
|
||||
//初始化之间数据图层
|
||||
initQsRecordDataLayer()
|
||||
addLayer(mDefaultMarkerLayer, NIMapView.LAYER_GROUPS.OPERATE_MARKER);
|
||||
// 设置矢量图层均在12级以上才显示
|
||||
mMapView.vtmMap.events.bind(Map.UpdateListener { e, mapPosition ->
|
||||
if (e == Map.SCALE_EVENT) {
|
||||
itemizedLayer.isEnabled = mapPosition.getZoomLevel() >= 12
|
||||
qsRecordItemizedLayer.isEnabled = mapPosition.getZoomLevel() >= 12
|
||||
niLocationItemizedLayer.isEnabled = mapPosition.getZoomLevel() >= 12
|
||||
}
|
||||
})
|
||||
mMapView.updateMap()
|
||||
}
|
||||
|
||||
fun setOnQsRecordItemClickListener(listener: OnQsRecordItemClickListener?) {
|
||||
itemListener = listener
|
||||
}
|
||||
|
||||
//增加marker
|
||||
/**
|
||||
* 增加marker
|
||||
*/
|
||||
fun addMarker(
|
||||
geoPoint: GeoPoint,
|
||||
title: String?,
|
||||
description: String? = ""
|
||||
description: String? = "",
|
||||
uid: java.lang.Object? = null,
|
||||
) {
|
||||
var marker: MarkerItem? = null
|
||||
for (e in mDefaultMarkerLayer.itemList) {
|
||||
@@ -121,16 +299,17 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
}
|
||||
}
|
||||
if (marker == null) {
|
||||
var tempTitle = title;
|
||||
var tempTitle = title
|
||||
if (tempTitle.isNullOrBlank()) {
|
||||
tempTitle = StringUtil.createUUID();
|
||||
tempTitle = StringUtil.createUUID()
|
||||
}
|
||||
val marker = MarkerItem(
|
||||
uid,
|
||||
tempTitle,
|
||||
description,
|
||||
geoPoint
|
||||
)
|
||||
mDefaultMarkerLayer.addItem(marker);
|
||||
mDefaultMarkerLayer.addItem(marker)
|
||||
mMapView.vtmMap.updateMap(true)
|
||||
} else {
|
||||
marker.description = description
|
||||
@@ -141,6 +320,17 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
}
|
||||
}
|
||||
|
||||
fun getCurrentMark(): MarkerInterface? {
|
||||
|
||||
if (mDefaultMarkerLayer != null) {
|
||||
return mDefaultMarkerLayer.itemList[mDefaultMarkerLayer.itemList.size - 1]
|
||||
}
|
||||
return null
|
||||
}
|
||||
|
||||
/**
|
||||
* 移除marker
|
||||
*/
|
||||
fun removeMarker(title: String) {
|
||||
var marker: MarkerItem? = null
|
||||
for (e in mDefaultMarkerLayer.itemList) {
|
||||
@@ -159,32 +349,63 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
/**
|
||||
* 增加或更新marker
|
||||
*/
|
||||
suspend fun addOrUpdateQsRecordMark(data: QsRecordBean) {
|
||||
for (item in itemizedLayer.itemList) {
|
||||
fun addOrUpdateQsRecordMark(data: QsRecordBean) {
|
||||
for (item in qsRecordItemizedLayer.itemList) {
|
||||
if (item is MarkerItem) {
|
||||
if (item.title == data.id) {
|
||||
itemizedLayer.itemList.remove(item)
|
||||
qsRecordItemizedLayer.itemList.remove(item)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
createMarkerItem(data)
|
||||
withContext(Dispatchers.Main) {
|
||||
mMapView.updateMap(true)
|
||||
}
|
||||
|
||||
createQsRecordMarker(data)
|
||||
mMapView.updateMap(true)
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 删除marker
|
||||
* 增加或更新便签
|
||||
*/
|
||||
suspend fun removeQsRecordMark(data: QsRecordBean) {
|
||||
for (item in itemizedLayer.itemList) {
|
||||
fun addOrUpdateNoteMark(data: NoteBean) {
|
||||
for (item in noteLayer.itemList) {
|
||||
if (item is MarkerItem) {
|
||||
if (item.title == data.id) {
|
||||
itemizedLayer.itemList.remove(item)
|
||||
itemizedLayer.populate()
|
||||
noteLayer.itemList.remove(item)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
noteLineLayer.removeNoteBeanLines(data)
|
||||
createNoteMarkerItem(data)
|
||||
mMapView.updateMap(true)
|
||||
}
|
||||
|
||||
|
||||
private fun convertGeometry2Drawable(geometry: Geometry, vectorLayerStyle: Style): Drawable? {
|
||||
var resultDrawable: Drawable? = null
|
||||
if ("POINT" == geometry.geometryType.uppercase(Locale.getDefault())) {
|
||||
val geoPoint = GeoPoint(geometry.coordinate.y, geometry.coordinate.x)
|
||||
resultDrawable = PointDrawable(geoPoint, vectorLayerStyle)
|
||||
} else if ("LINESTRING" == geometry.geometryType.uppercase(Locale.getDefault())) {
|
||||
val lineString = geometry as LineString
|
||||
resultDrawable = LineDrawable(lineString, vectorLayerStyle)
|
||||
} else if ("POLYGON" == geometry.geometryType.uppercase(Locale.getDefault())) {
|
||||
val polygon = geometry as Polygon
|
||||
resultDrawable = PolygonDrawable(polygon, vectorLayerStyle)
|
||||
}
|
||||
return resultDrawable
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 删除质检数据
|
||||
*/
|
||||
fun removeQsRecordMark(data: QsRecordBean) {
|
||||
for (item in qsRecordItemizedLayer.itemList) {
|
||||
if (item is MarkerItem) {
|
||||
if (item.title == data.id) {
|
||||
qsRecordItemizedLayer.itemList.remove(item)
|
||||
qsRecordItemizedLayer.populate()
|
||||
return
|
||||
}
|
||||
}
|
||||
@@ -192,152 +413,141 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
}
|
||||
|
||||
/**
|
||||
* 初始话质检数据图层
|
||||
* 删除标签
|
||||
*/
|
||||
private fun initQsRecordDataLayer() {
|
||||
|
||||
canvas = CanvasAdapter.newCanvas()
|
||||
paint = CanvasAdapter.newPaint()
|
||||
paint.setTypeface(Paint.FontFamily.DEFAULT, Paint.FontStyle.NORMAL)
|
||||
paint.setTextSize(NUM_13 * CanvasAdapter.getScale())
|
||||
paint.strokeWidth = 2 * CanvasAdapter.getScale()
|
||||
paint.color = Color.parseColor(mDefaultTextColor)
|
||||
val bitmapPoi: Bitmap = AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
mContext.resources,
|
||||
R.mipmap.map_icon_blue2
|
||||
)
|
||||
)
|
||||
val symbol = MarkerSymbol(bitmapPoi, MarkerSymbol.HotspotPlace.BOTTOM_CENTER)
|
||||
markerRendererFactory = MarkerRendererFactory { markerLayer ->
|
||||
object : ClusterMarkerRenderer(
|
||||
mContext,
|
||||
markerLayer,
|
||||
symbol,
|
||||
ClusterStyle(
|
||||
org.oscim.backend.canvas.Color.WHITE,
|
||||
org.oscim.backend.canvas.Color.BLUE
|
||||
)
|
||||
) {
|
||||
// override fun getClusterBitmap(size: Int): Bitmap? {
|
||||
// return super.getclusterbitmap(size)
|
||||
// }
|
||||
fun removeNoteMark(data: NoteBean) {
|
||||
for (item in noteLayer.itemList) {
|
||||
if (item is MarkerItem) {
|
||||
if (item.title == data.id) {
|
||||
noteLayer.itemList.remove(item)
|
||||
noteLineLayer.removeNoteBeanLines(data)
|
||||
noteLayer.populate()
|
||||
mMapView.updateMap(true)
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
itemizedLayer =
|
||||
MyItemizedLayer(
|
||||
mMapView.vtmMap,
|
||||
mutableListOf(),
|
||||
markerRendererFactory,
|
||||
object : MyItemizedLayer.OnItemGestureListener {
|
||||
override fun onItemSingleTapUp(
|
||||
list: MutableList<Int>,
|
||||
nearest: Int
|
||||
): Boolean {
|
||||
itemListener?.let {
|
||||
val idList = mutableListOf<String>()
|
||||
if (list.size == 0) {
|
||||
} else {
|
||||
for (i in list) {
|
||||
val markerInterface: MarkerInterface =
|
||||
itemizedLayer.itemList[i]
|
||||
if (markerInterface is MarkerItem) {
|
||||
idList.add(markerInterface.title)
|
||||
}
|
||||
}
|
||||
it.onQsRecordList(idList.distinct().toMutableList())
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun onItemLongPress(
|
||||
list: MutableList<Int>?,
|
||||
nearest: Int
|
||||
): Boolean {
|
||||
return true
|
||||
}
|
||||
})
|
||||
addLayer(itemizedLayer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
mContext.lifecycleScope.launch(Dispatchers.IO) {
|
||||
var list = mutableListOf<QsRecordBean>()
|
||||
val realm = Realm.getDefaultInstance()
|
||||
realm.executeTransaction {
|
||||
val objects = realm.where<QsRecordBean>().findAll()
|
||||
list = realm.copyFromRealm(objects)
|
||||
}
|
||||
// realm.close()
|
||||
|
||||
for (item in list) {
|
||||
createMarkerItem(item)
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private suspend fun createMarkerItem(item: QsRecordBean) {
|
||||
|
||||
/**
|
||||
* 添加质检数据marker
|
||||
*/
|
||||
private fun createNoteMarkerItem(item: NoteBean) {
|
||||
val bitmap: Bitmap = createTextMarkerBitmap(mContext, item.description, noteResId)
|
||||
val geometry: Geometry? = GeometryTools.createGeometry(item.guideGeometry)
|
||||
if (geometry != null) {
|
||||
var geoPoint: GeoPoint? = null
|
||||
if (geometry.geometryType != null) {
|
||||
when (geometry.geometryType.uppercase(Locale.getDefault())) {
|
||||
"POINT" -> geoPoint =
|
||||
GeoPoint(geometry.coordinate.y, geometry.coordinate.x)
|
||||
}
|
||||
}
|
||||
if (geoPoint != null) {
|
||||
val geoMarkerItem: MarkerItem
|
||||
geoMarkerItem = ClusterMarkerItem(
|
||||
1, item.id, item.description, geoPoint
|
||||
)
|
||||
val markerSymbol =
|
||||
MarkerSymbol(bitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
geoMarkerItem.marker = markerSymbol
|
||||
noteLayer.itemList.add(geoMarkerItem)
|
||||
}
|
||||
}
|
||||
noteLineLayer.showNoteBeanLines(item)
|
||||
noteLayer.populate()
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 添加质检数据marker
|
||||
*/
|
||||
private fun createQsRecordMarker(item: QsRecordBean) {
|
||||
val bitmap: Bitmap = createTextMarkerBitmap(mContext, item.description, resId)
|
||||
if (item.t_lifecycle != 2) {
|
||||
val geometry: Geometry? = GeometryTools.createGeometry(item.geometry)
|
||||
if (geometry != null) {
|
||||
var geoPoint: org.oscim.core.GeoPoint? = null
|
||||
var geoPoint: GeoPoint? = null
|
||||
if (geometry.geometryType != null) {
|
||||
when (geometry.geometryType.uppercase(Locale.getDefault())) {
|
||||
"POINT" -> geoPoint =
|
||||
org.oscim.core.GeoPoint(geometry.coordinate.y, geometry.coordinate.x)
|
||||
// "LINESTRING" -> {
|
||||
// val lineString = geometry as LineString
|
||||
// if (lineString != null && lineString.coordinates.size > 0) {
|
||||
// geoPoint = GeoPoint(
|
||||
// lineString.coordinates[0].y,
|
||||
// lineString.coordinates[0].x
|
||||
// )
|
||||
// }
|
||||
// val drawableLine: Drawable =
|
||||
// convertGeometry2Drawable(geometry, lineStyle)
|
||||
// if (drawableLine != null) {
|
||||
// dataVectorLayer.add(drawableLine)
|
||||
// }
|
||||
// }
|
||||
// "POLYGON" -> {
|
||||
// val polygon = geometry as Polygon
|
||||
// if (polygon != null && polygon.coordinates.size > 0) {
|
||||
// geoPoint = GeoPoint(
|
||||
// polygon.coordinates[0].y,
|
||||
// polygon.coordinates[0].x
|
||||
// )
|
||||
// }
|
||||
// val drawablePolygon: Drawable =
|
||||
// convertGeometry2Drawable(geometry, polygonStyle)
|
||||
// if (drawablePolygon != null) {
|
||||
// dataVectorLayer.add(drawablePolygon)
|
||||
// }
|
||||
// }
|
||||
GeoPoint(geometry.coordinate.y, geometry.coordinate.x)
|
||||
}
|
||||
}
|
||||
if (geoPoint != null) {
|
||||
var geoMarkerItem: MarkerItem
|
||||
// if (item.getType() === 1) {
|
||||
geoMarkerItem = ClusterMarkerItem(
|
||||
1, item.id, item.description, geoPoint
|
||||
)
|
||||
// } else {
|
||||
// geoMarkerItem = MarkerItem(
|
||||
// ePointTemp.getType(),
|
||||
// ePointTemp.getId(),
|
||||
// ePointTemp.getStyleText(),
|
||||
// geoPoint
|
||||
// )
|
||||
// }
|
||||
val markerSymbol =
|
||||
MarkerSymbol(bitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
|
||||
val geoMarkerItem: MarkerItem
|
||||
|
||||
geoMarkerItem = ClusterMarkerItem(1, item.id, item.description, geoPoint)
|
||||
|
||||
val markerSymbol = MarkerSymbol(bitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
|
||||
geoMarkerItem.marker = markerSymbol
|
||||
itemizedLayer.itemList.add(geoMarkerItem)
|
||||
|
||||
qsRecordItemizedLayer.itemList.add(geoMarkerItem)
|
||||
}
|
||||
}
|
||||
}
|
||||
itemizedLayer.populate()
|
||||
qsRecordItemizedLayer.populate()
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加质检数据marker
|
||||
*/
|
||||
fun addNiLocationMarkerItem(niLocation: NiLocation) {
|
||||
synchronized(this) {
|
||||
var geoMarkerItem = createNILocationBitmap(niLocation)
|
||||
niLocationItemizedLayer.addItem(geoMarkerItem)
|
||||
niLocationItemizedLayer.update()
|
||||
}
|
||||
}
|
||||
|
||||
private fun createNILocationBitmap(niLocation: NiLocation): MarkerItem {
|
||||
|
||||
val direction: Double = niLocation.direction
|
||||
|
||||
val geoMarkerItem: MarkerItem = ClusterMarkerItem(
|
||||
niLocation,
|
||||
niLocation.id,
|
||||
niLocation.time,
|
||||
GeoPoint(niLocation.latitude, niLocation.longitude)
|
||||
)
|
||||
|
||||
//角度
|
||||
when (niLocation.media) {
|
||||
0 -> {
|
||||
//角度不为0时需要预先设置marker样式并进行角度设置,否则使用图层默认的sym即可
|
||||
//角度不为0时需要预先设置marker样式并进行角度设置,否则使用图层默认的sym即可
|
||||
if (direction > 0.0) {
|
||||
val symbolGpsTemp =
|
||||
MarkerSymbol(niLocationBitmap, MarkerSymbol.HotspotPlace.CENTER, false)
|
||||
geoMarkerItem.marker = symbolGpsTemp
|
||||
geoMarkerItem.setRotation(direction.toFloat())
|
||||
} else {
|
||||
val symbolGpsTemp =
|
||||
MarkerSymbol(niLocationBitmap2, MarkerSymbol.HotspotPlace.CENTER, false)
|
||||
geoMarkerItem.marker = symbolGpsTemp
|
||||
}
|
||||
}
|
||||
|
||||
1 -> {
|
||||
//角度不为0时需要预先设置marker样式并进行角度设置,否则使用图层默认的sym即可
|
||||
//角度不为0时需要预先设置marker样式并进行角度设置,否则使用图层默认的sym即可
|
||||
if (direction > 0.0) {
|
||||
val symbolLidarTemp =
|
||||
MarkerSymbol(niLocationBitmap1, MarkerSymbol.HotspotPlace.CENTER, false)
|
||||
geoMarkerItem.marker = symbolLidarTemp
|
||||
geoMarkerItem.setRotation(direction.toFloat())
|
||||
} else {
|
||||
val symbolGpsTemp =
|
||||
MarkerSymbol(niLocationBitmap3, MarkerSymbol.HotspotPlace.CENTER, false)
|
||||
geoMarkerItem.marker = symbolGpsTemp
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return geoMarkerItem
|
||||
}
|
||||
|
||||
|
||||
@@ -530,7 +740,7 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
val originBitmap = android.graphics.Bitmap.createBitmap(
|
||||
if (drawable.intrinsicWidth > maxWidth) drawable.intrinsicWidth else maxWidth.toInt(),
|
||||
drawable.intrinsicHeight * 2,
|
||||
android.graphics.Bitmap.Config.ARGB_4444
|
||||
android.graphics.Bitmap.Config.ARGB_8888
|
||||
)
|
||||
val androidCanvas = Canvas(originBitmap)
|
||||
val startX = (originBitmap.width - drawable.intrinsicWidth) / 2
|
||||
@@ -550,8 +760,65 @@ class MarkHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
bitmap
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 移除轨迹图层
|
||||
*/
|
||||
fun clearNiLocationLayer() {
|
||||
niLocationItemizedLayer.removeAllItems()
|
||||
niLocationItemizedLayer.update()
|
||||
}
|
||||
|
||||
/**
|
||||
* 移除所有质检数据
|
||||
*/
|
||||
fun removeAllQsMarker() {
|
||||
qsRecordItemizedLayer.removeAllItems()
|
||||
mMapView.updateMap(true)
|
||||
}
|
||||
|
||||
fun getNILocationItemizedLayerSize(): Int {
|
||||
return niLocationItemizedLayer.itemList.size
|
||||
}
|
||||
|
||||
fun getNILocation(index: Int): NiLocation? {
|
||||
return if (index > -1 && index < getNILocationItemizedLayerSize()) {
|
||||
((niLocationItemizedLayer.itemList[index]) as MarkerItem).uid as NiLocation
|
||||
} else {
|
||||
null
|
||||
}
|
||||
}
|
||||
|
||||
fun getNILocationIndex(niLocation: NiLocation): Int? {
|
||||
|
||||
var list = niLocationItemizedLayer.itemList
|
||||
|
||||
if (niLocation != null && list.isNotEmpty()) {
|
||||
|
||||
var index = -1
|
||||
|
||||
list.forEach {
|
||||
|
||||
index += 1
|
||||
|
||||
if (((it as MarkerItem).uid as NiLocation).id.equals(niLocation.id)) {
|
||||
return index
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return -1
|
||||
}
|
||||
}
|
||||
|
||||
interface OnQsRecordItemClickListener {
|
||||
fun onQsRecordList(list: MutableList<String>)
|
||||
interface OnQsRecordItemClickListener : BaseClickListener {
|
||||
fun onQsRecordList(tag: String, list: MutableList<String>)
|
||||
}
|
||||
|
||||
interface ONNoteItemClickListener : BaseClickListener {
|
||||
fun onNote(tag: String, noteId: String)
|
||||
}
|
||||
|
||||
interface OnNiLocationItemListener : BaseClickListener {
|
||||
fun onNiLocation(tag: String, index: Int, it: NiLocation)
|
||||
}
|
||||
@@ -3,15 +3,17 @@ package com.navinfo.collect.library.map.handler
|
||||
import android.graphics.BitmapFactory
|
||||
import android.graphics.Canvas
|
||||
import android.graphics.Color
|
||||
import android.os.Build
|
||||
import android.text.TextPaint
|
||||
import androidx.annotation.RequiresApi
|
||||
import android.util.Log
|
||||
import android.widget.Toast
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import androidx.lifecycle.MutableLiveData
|
||||
import com.navinfo.collect.library.R
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import com.navinfo.collect.library.map.layers.NIPolygonLayer
|
||||
import com.navinfo.collect.library.utils.DistanceUtil
|
||||
import com.navinfo.collect.library.utils.GeometryTools
|
||||
import com.navinfo.collect.library.utils.StringUtil.Companion.createUUID
|
||||
import org.oscim.android.canvas.AndroidBitmap
|
||||
import org.oscim.backend.CanvasAdapter
|
||||
import org.oscim.backend.canvas.Bitmap
|
||||
@@ -27,8 +29,9 @@ import org.oscim.layers.vector.PathLayer
|
||||
import org.oscim.layers.vector.geometries.Style
|
||||
import org.oscim.map.Map
|
||||
import java.math.BigDecimal
|
||||
import kotlin.math.abs
|
||||
import kotlin.math.ceil
|
||||
|
||||
@RequiresApi(Build.VERSION_CODES.M)
|
||||
open class MeasureLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
BaseHandler(context, mapView), Map.UpdateListener {
|
||||
|
||||
@@ -37,241 +40,249 @@ open class MeasureLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
private var bDrawLine = false
|
||||
private val bDrawPoint = false
|
||||
|
||||
private var mAreaLayer: ItemizedLayer
|
||||
/**
|
||||
* 加上虚线的总长度
|
||||
*/
|
||||
val tempLineDistanceLiveData = MutableLiveData("")
|
||||
|
||||
/**
|
||||
* 实际绘制的总长度
|
||||
*/
|
||||
val lineLengthLiveData = MutableLiveData(0.000)
|
||||
|
||||
private val markerLayer: ItemizedLayer by lazy {
|
||||
|
||||
val markerSymbol = MarkerSymbol(
|
||||
mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER
|
||||
)
|
||||
//新增marker图层
|
||||
val layer = ItemizedLayer(
|
||||
mapView.vtmMap, mutableListOf<MarkerInterface>(), markerSymbol, itemGestureListener
|
||||
)
|
||||
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_MARKER)
|
||||
layer
|
||||
}
|
||||
|
||||
private val mAreaLayer: ItemizedLayer by lazy {
|
||||
val markerSymbol = MarkerSymbol(mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
ItemizedLayer(mMapView.vtmMap, ArrayList(), markerSymbol, null)
|
||||
}
|
||||
|
||||
//绘制线 样式
|
||||
private val lineStyle: Style
|
||||
private val lineStyle: Style by lazy {
|
||||
//新增线数据图层和线样式
|
||||
Style.builder().scaleZoomLevel(20).buffer(1.0)
|
||||
.stippleColor(context.resources.getColor(R.color.draw_line_blue1_color))
|
||||
.strokeWidth(4f)
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_blue2_color))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color))
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_red_color))
|
||||
.stippleWidth(4f).fixed(true).build()
|
||||
}
|
||||
|
||||
private val newTempStyle: Style
|
||||
private val newTempStyle: Style by lazy {
|
||||
Style.builder().stippleColor(context.resources.getColor(R.color.transparent))
|
||||
.stipple(30).stippleWidth(30f).strokeWidth(4f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color))
|
||||
.fixed(true).randomOffset(false).build()
|
||||
}
|
||||
|
||||
//线型编辑时的样式
|
||||
private val editTempStyle: Style
|
||||
private val editTempStyle: Style by lazy {
|
||||
Style.builder().stippleColor(context.resources.getColor(R.color.transparent))
|
||||
.stipple(30).stippleWidth(30f).strokeWidth(8f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color)).fixed(true)
|
||||
.randomOffset(false).build()
|
||||
|
||||
}
|
||||
|
||||
//新增线数据引线
|
||||
private var mPathLayerTemp: PathLayer
|
||||
private val mPathLayerTemp: PathLayer by lazy {
|
||||
val layer = PathLayer(mMapView.vtmMap, newTempStyle)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
layer
|
||||
}
|
||||
|
||||
//新增线数据
|
||||
private var mPathLayer: PathLayer
|
||||
val mPathLayer: PathLayer by lazy {
|
||||
val layer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
layer
|
||||
}
|
||||
|
||||
//线路端点图标
|
||||
private var mPathMarkerBitmap: Bitmap
|
||||
private val mPathMarkerBitmap: Bitmap by lazy {
|
||||
AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources, R.mipmap.icon_path_maker
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
private var bDrawPolygon = false
|
||||
|
||||
private var mPolygonLayer: NIPolygonLayer
|
||||
|
||||
init {
|
||||
|
||||
//新增线数据图层和线样式
|
||||
lineStyle = Style.builder().scaleZoomLevel(20).buffer(1.0)
|
||||
.stippleColor(context.resources.getColor(R.color.draw_line_blue1_color, null))
|
||||
.strokeWidth(4f)
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fillAlpha(0.5f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fillColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.stippleWidth(4f)
|
||||
.fixed(true)
|
||||
.build()
|
||||
|
||||
newTempStyle = Style.builder()
|
||||
.stippleColor(context.resources.getColor(R.color.transparent, null))
|
||||
.stipple(30)
|
||||
.stippleWidth(30f)
|
||||
.strokeWidth(4f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_blue2_color, null))
|
||||
.fixed(true)
|
||||
.randomOffset(false)
|
||||
.build()
|
||||
|
||||
editTempStyle = Style.builder()
|
||||
.stippleColor(context.resources.getColor(R.color.transparent, null))
|
||||
.stipple(30)
|
||||
.stippleWidth(30f)
|
||||
.strokeWidth(8f)
|
||||
.strokeColor(context.resources.getColor(R.color.draw_line_red_color, null))
|
||||
.fixed(true)
|
||||
.randomOffset(false)
|
||||
.build()
|
||||
|
||||
mPolygonLayer = NIPolygonLayer(
|
||||
mMapView.vtmMap,
|
||||
lineStyle
|
||||
)
|
||||
// addLayer(mPolygonLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
|
||||
mPathLayerTemp = PathLayer(mMapView.vtmMap, newTempStyle)
|
||||
// addLayer(mPathLayerTemp, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
|
||||
mPathMarkerBitmap = AndroidBitmap(
|
||||
BitmapFactory.decodeResource(
|
||||
context.resources,
|
||||
R.mipmap.icon_path_maker
|
||||
)
|
||||
)
|
||||
|
||||
val markerSymbol = MarkerSymbol(mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
|
||||
mAreaLayer = ItemizedLayer(mMapView.vtmMap, ArrayList(), markerSymbol, null)
|
||||
|
||||
mPathLayer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
|
||||
addLayer(mPathLayer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
|
||||
val mPolygonLayer: NIPolygonLayer by lazy {
|
||||
val layer = NIPolygonLayer(mMapView.vtmMap, lineStyle)
|
||||
addLayer(layer, NIMapView.LAYER_GROUPS.OPERATE_LINE)
|
||||
layer
|
||||
}
|
||||
|
||||
open fun drawLineOrPolygon(type: Int) {
|
||||
|
||||
init {
|
||||
mMapView.vtmMap.events.bind(this)
|
||||
}
|
||||
|
||||
open fun drawLineOrPolygon(isPolygon: Boolean) {
|
||||
bDrawLine = true
|
||||
|
||||
// //画面
|
||||
// if (type == 3) {
|
||||
// if (mPolygonLayer == null) {
|
||||
// mPolygonLayer = NIPolygonLayer(mMapView.vtmMap, lineStyle)
|
||||
// addLayer(mPolygonLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
// } else if (!mPolygonLayer.isEnabled) {
|
||||
// mPolygonLayer.isEnabled = true
|
||||
// }
|
||||
// } else {
|
||||
// if (mPathLayer == null) {
|
||||
// mPathLayer = PathLayer(mMapView.vtmMap, lineStyle)
|
||||
// addLayer(mPathLayer, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
// } else if (!mPathLayer.isEnabled()) {
|
||||
// mPathLayer.setEnabled(true)
|
||||
// }
|
||||
// }
|
||||
// //上一个点的引线
|
||||
// if (mPathLayerTemp == null) {
|
||||
// mPathLayerTemp = PathLayer(mMapView.vtmMap, newTempStyle)
|
||||
// addLayer(mPathLayerTemp, NIMapView.LAYER_GROUPS.OPERATE)
|
||||
// } else if (!mPathLayerTemp.isEnabled) {
|
||||
// mPathLayerTemp.isEnabled = true
|
||||
// }
|
||||
// val geoPoint: GeoPoint =
|
||||
// GeoPoint(
|
||||
// mMapView.vtmMap.getMapPosition().getLatitude(),
|
||||
// mMapView.vtmMap.getMapPosition().getLongitude()
|
||||
// )
|
||||
//
|
||||
// //编辑点
|
||||
// if (editIndex > -1) {
|
||||
// if (mPathMakers.size > editIndex) {
|
||||
// mMapView.layerManager.removeMarker(
|
||||
// mPathMakers[editIndex],
|
||||
// NILayerManager.MARQUEE_MARKER_LAYER
|
||||
// )
|
||||
// mPathMakers.removeAt(editIndex)
|
||||
// if (mPathMarkerBitmap == null) {
|
||||
// mPathMarkerBitmap = AndroidBitmap(
|
||||
// BitmapFactory.decodeResource(
|
||||
// mContext.getResources(),
|
||||
// R.mipmap.icon_path_maker
|
||||
// )
|
||||
// )
|
||||
// }
|
||||
// val markerItem = MarkerItem(createUUID(), "", "", geoPoint)
|
||||
// val markerSymbol = MarkerSymbol(mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
// markerItem.marker = markerSymbol
|
||||
// mMapView.layerManager.addMarker2MarkerLayer(
|
||||
// markerItem,
|
||||
// mPathMarkerBitmap,
|
||||
// NILayerManager.MARQUEE_MARKER_LAYER,
|
||||
// NIMapView.LAYER_GROUPS.OTHER.ordinal,
|
||||
// itemGestureListener
|
||||
// )
|
||||
// mPathMakers.add(editIndex, markerItem)
|
||||
// if (mPathLayer != null && mPathLayer.getPoints().size > 0) {
|
||||
// val list: MutableList<GeoPoint> = mPathLayer.getPoints()
|
||||
// if (editIndex < list.size) {
|
||||
// list.removeAt(editIndex)
|
||||
// val list2: MutableList<GeoPoint> = java.util.ArrayList(list)
|
||||
// list2.add(editIndex, geoPoint)
|
||||
// mPathLayer.setPoints(list2)
|
||||
// }
|
||||
// } else if (mPolygonLayer != null && mPolygonLayer.points.size > 0) {
|
||||
// val list = mPolygonLayer.points
|
||||
// if (editIndex < list.size) {
|
||||
// list.removeAt(editIndex)
|
||||
// val list2: MutableList<GeoPoint> = java.util.ArrayList(list)
|
||||
// list2.add(editIndex, geoPoint)
|
||||
// mPolygonLayer.setPoints(list2)
|
||||
// }
|
||||
// }
|
||||
// if (mPathLayerTemp != null) {
|
||||
// mPathLayerTemp.setStyle(newTempStyle)
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>()
|
||||
// if (type == 3 && mPathMakers.size > 1) {
|
||||
// list.add(mPathMakers[0].geoPoint)
|
||||
// list.add(geoPoint)
|
||||
// list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
// } else {
|
||||
// list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
// list.add(geoPoint)
|
||||
// }
|
||||
// mPathLayerTemp.setPoints(list)
|
||||
// }
|
||||
// }
|
||||
// editIndex = -1
|
||||
// } else { //新增点
|
||||
// if (type == 3) {
|
||||
// val points: MutableList<GeoPoint> = java.util.ArrayList(mPolygonLayer.points)
|
||||
// if (points.size > 2) {
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList()
|
||||
// points.add(points[0])
|
||||
// list.add(points[0])
|
||||
// list.add(geoPoint)
|
||||
// list.add(mPolygonLayer.points[mPolygonLayer.points.size - 1])
|
||||
// val bCross = GeometryTools.isPolygonCrosses(points, list)
|
||||
// if (bCross == true) {
|
||||
// Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
// return
|
||||
// }
|
||||
// }
|
||||
// mPolygonLayer.addPoint(geoPoint)
|
||||
// } else {
|
||||
// val points: List<GeoPoint> = mPathLayer.getPoints()
|
||||
// if (points.size > 2) {
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList()
|
||||
// list.add(geoPoint)
|
||||
// list.add(points[points.size - 1])
|
||||
// val bCross = GeometryTools.isLineStringCrosses(points, list)
|
||||
// if (bCross == true) {
|
||||
// Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
// return
|
||||
// }
|
||||
// }
|
||||
// mPathLayer.addPoint(geoPoint)
|
||||
// }
|
||||
// if (mPathMarkerBitmap == null) {
|
||||
// mPathMarkerBitmap = AndroidBitmap(
|
||||
// BitmapFactory.decodeResource(
|
||||
// mContext.getResources(),
|
||||
// R.mipmap.icon_path_maker
|
||||
// )
|
||||
// )
|
||||
// }
|
||||
// val markerItem = MarkerItem(createUUID(), "", "", geoPoint)
|
||||
// val markerSymbol = MarkerSymbol(mPathMarkerBitmap, MarkerSymbol.HotspotPlace.CENTER)
|
||||
// markerItem.marker = markerSymbol
|
||||
// mMapView.layerManager.addMarker2MarkerLayer(
|
||||
// markerItem,
|
||||
// mPathMarkerBitmap,
|
||||
// NILayerManager.MARQUEE_MARKER_LAYER,
|
||||
// NIMapView.LAYER_GROUPS.OTHER.ordinal,
|
||||
// itemGestureListener
|
||||
// )
|
||||
// mPathMakers.add(markerItem)
|
||||
// }
|
||||
//画面
|
||||
if (isPolygon && !mPolygonLayer.isEnabled) {
|
||||
mPolygonLayer.isEnabled = true
|
||||
} else if (!mPathLayer.isEnabled) {
|
||||
mPathLayer.isEnabled = true
|
||||
}
|
||||
//上一个点的引线
|
||||
if (!mPathLayerTemp.isEnabled) {
|
||||
mPathLayerTemp.isEnabled = true
|
||||
}
|
||||
val geoPoint = GeoPoint(
|
||||
mMapView.vtmMap.mapPosition.latitude, mMapView.vtmMap.mapPosition.longitude
|
||||
)
|
||||
|
||||
//编辑点
|
||||
if (editIndex > -1) {
|
||||
if (mPathMakers.size > editIndex) {
|
||||
markerLayer.removeItem(editIndex)
|
||||
mPathMakers.removeAt(editIndex)
|
||||
val markerItem = MarkerItem(createUUID(), "", "", geoPoint)
|
||||
markerLayer.addItem(markerItem)
|
||||
mPathMakers.add(editIndex, markerItem)
|
||||
if (mPathLayer.points.size > 0) {
|
||||
val list: MutableList<GeoPoint> = mPathLayer.points
|
||||
if (editIndex < list.size) {
|
||||
list.removeAt(editIndex)
|
||||
val list2: MutableList<GeoPoint> = java.util.ArrayList(list)
|
||||
list2.add(editIndex, geoPoint)
|
||||
mPathLayer.setPoints(list2)
|
||||
}
|
||||
} else if (mPolygonLayer.points.size > 0) {
|
||||
val list = mPolygonLayer.points
|
||||
if (editIndex < list.size) {
|
||||
list.removeAt(editIndex)
|
||||
val list2: MutableList<GeoPoint> = java.util.ArrayList(list)
|
||||
list2.add(editIndex, geoPoint)
|
||||
mPolygonLayer.setPoints(list2)
|
||||
}
|
||||
}
|
||||
mPathLayerTemp.setStyle(newTempStyle)
|
||||
val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>()
|
||||
if (isPolygon && mPathMakers.size > 1) {
|
||||
list.add(mPathMakers[0].geoPoint)
|
||||
list.add(geoPoint)
|
||||
list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
} else {
|
||||
list.add(mPathMakers[mPathMakers.size - 1].geoPoint)
|
||||
list.add(geoPoint)
|
||||
}
|
||||
mPathLayerTemp.setPoints(list)
|
||||
}
|
||||
editIndex = -1
|
||||
} else { //新增点
|
||||
if (isPolygon) {
|
||||
val points: MutableList<GeoPoint> = java.util.ArrayList(mPolygonLayer.points)
|
||||
if (points.size > 2) {
|
||||
val list: MutableList<GeoPoint> = java.util.ArrayList()
|
||||
points.add(points[0])
|
||||
list.add(points[0])
|
||||
list.add(geoPoint)
|
||||
list.add(mPolygonLayer.points[mPolygonLayer.points.size - 1])
|
||||
val bCross = GeometryTools.isPolygonCrosses(points, list)
|
||||
if (bCross) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return
|
||||
}
|
||||
}
|
||||
mPolygonLayer.addPoint(geoPoint)
|
||||
} else {
|
||||
val points: List<GeoPoint> = mPathLayer.points
|
||||
if (points.size > 2) {
|
||||
val list: MutableList<GeoPoint> = java.util.ArrayList()
|
||||
list.add(geoPoint)
|
||||
list.add(points[points.size - 1])
|
||||
val bCross = GeometryTools.isLineStringCrosses(points, list)
|
||||
if (bCross) {
|
||||
Toast.makeText(mContext, "不能交叉", Toast.LENGTH_SHORT).show()
|
||||
return
|
||||
}
|
||||
}
|
||||
mPathLayer.addPoint(geoPoint)
|
||||
if (mPathLayer.points.size > 1) {
|
||||
val distance: Double = GeometryTools.getDistance(mPathLayer.points)
|
||||
val bg = BigDecimal(distance)
|
||||
val f1 = bg.setScale(3, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
lineLengthLiveData.value = f1
|
||||
} else {
|
||||
lineLengthLiveData.value = 0.000
|
||||
}
|
||||
}
|
||||
val markerItem = MarkerItem(createUUID(), "", "", geoPoint)
|
||||
markerLayer.addItem(markerItem)
|
||||
mPathMakers.add(markerItem)
|
||||
}
|
||||
showAreaLayer()
|
||||
}
|
||||
|
||||
/**
|
||||
* 绘制线回退点
|
||||
*/
|
||||
open fun drawLineBackspace() {
|
||||
// if (mPathLayer != null && mPathLayer.getPoints().size > 0) {
|
||||
if (mPathLayer.points.size > 0) {
|
||||
val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>(mPathLayer.getPoints())
|
||||
val point = list[mPathLayer.points.size - 1]
|
||||
list.remove(point)
|
||||
mPathLayer.setPoints(list)
|
||||
mMapView.vtmMap.animator().animateTo(
|
||||
GeoPoint(
|
||||
point.latitude, point.longitude
|
||||
)
|
||||
)
|
||||
}
|
||||
if (mPathMakers.size > 0) {
|
||||
var item: MarkerItem? = mPathMakers[mPathMakers.size - 1]
|
||||
markerLayer.removeItem(item)
|
||||
mPathMakers.remove(item)
|
||||
}
|
||||
if (mPathMakers.size == 0 && mPathLayerTemp != null) {
|
||||
mPathLayerTemp.clearPath()
|
||||
}
|
||||
editIndex = -1
|
||||
if (mPathLayerTemp != null) {
|
||||
mPathLayerTemp.setStyle(newTempStyle)
|
||||
}
|
||||
if (mPathLayer.points.size > 1) {
|
||||
val distance: Double = GeometryTools.getDistance(mPathLayer.points)
|
||||
val bg = BigDecimal(distance)
|
||||
val f1 = bg.setScale(3, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
lineLengthLiveData.value = f1
|
||||
} else {
|
||||
lineLengthLiveData.value = 0.000
|
||||
tempLineDistanceLiveData.value = "0米"
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 绘制面回退点
|
||||
*/
|
||||
open fun drawPolygonBackspace() {
|
||||
// if (mPathLayer.points.size > 0) {
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>(mPathLayer.getPoints())
|
||||
// val point = list[mPathLayer.getPoints().size - 1]
|
||||
// list.remove(point)
|
||||
// mPathLayer.setPoints(list)
|
||||
// mMapView.layerManager.jumpToPosition(point.longitude, point.latitude, 0)
|
||||
// } else if (mPolygonLayer != null && mPolygonLayer.points.size > 0) {
|
||||
// } else if (mPolygonLayer.points.size > 0) {
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>(mPolygonLayer.points)
|
||||
// val point = list[mPolygonLayer.points.size - 1]
|
||||
// list.remove(point)
|
||||
@@ -298,10 +309,8 @@ open class MeasureLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
* 隐藏面积计算
|
||||
*/
|
||||
open fun hideAreaLayer() {
|
||||
if (mAreaLayer != null) {
|
||||
mAreaLayer.removeAllItems()
|
||||
mMapView.vtmMap.layers().remove(mAreaLayer)
|
||||
}
|
||||
mAreaLayer.removeAllItems()
|
||||
mMapView.vtmMap.layers().remove(mAreaLayer)
|
||||
}
|
||||
|
||||
|
||||
@@ -309,46 +318,39 @@ open class MeasureLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
* 显示面积计算
|
||||
*/
|
||||
open fun showAreaLayer() {
|
||||
if (mAreaLayer != null) {
|
||||
mAreaLayer.removeAllItems()
|
||||
mMapView.vtmMap.layers().remove(mAreaLayer)
|
||||
}
|
||||
if (mPolygonLayer != null && mPolygonLayer.points.size > 2) {
|
||||
mAreaLayer.removeAllItems()
|
||||
mMapView.vtmMap.layers().remove(mAreaLayer)
|
||||
if (mPolygonLayer.points.size > 2) {
|
||||
val list: MutableList<GeoPoint> = ArrayList(mPolygonLayer.points)
|
||||
val area = DistanceUtil.planarPolygonAreaMeters2(list)
|
||||
var areaString: String
|
||||
if (area < 1000000) {
|
||||
areaString = area.toString() + "平方米"
|
||||
val areaString = if (area < 1000000) {
|
||||
area.toString() + "平方米"
|
||||
} else if (area < 10000000000.0) {
|
||||
val d = area / 1000000.0
|
||||
val bg = BigDecimal(d)
|
||||
val f1 = bg.setScale(1, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
areaString = f1.toString() + "平方公里"
|
||||
f1.toString() + "平方公里"
|
||||
} else {
|
||||
val d = area / 10000000000.0
|
||||
val bg = BigDecimal(d)
|
||||
val f1 = bg.setScale(1, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
areaString = f1.toString() + "万平方公里"
|
||||
f1.toString() + "万平方公里"
|
||||
}
|
||||
val textPaint = TextPaint()
|
||||
textPaint.textSize = 13 * CanvasAdapter.getScale()
|
||||
textPaint.color = Color.BLUE
|
||||
val width = Math.ceil(textPaint.measureText(areaString).toDouble()).toInt()
|
||||
val width = ceil(textPaint.measureText(areaString).toDouble()).toInt()
|
||||
val fontMetrics = textPaint.fontMetrics
|
||||
val height =
|
||||
Math.ceil((Math.abs(fontMetrics.bottom) + Math.abs(fontMetrics.top)).toDouble())
|
||||
.toInt()
|
||||
val height = ceil((abs(fontMetrics.bottom) + abs(fontMetrics.top)).toDouble()).toInt()
|
||||
val bitmap = android.graphics.Bitmap.createBitmap(
|
||||
width,
|
||||
height,
|
||||
android.graphics.Bitmap.Config.ARGB_8888
|
||||
width, height, android.graphics.Bitmap.Config.ARGB_8888
|
||||
)
|
||||
val canvas = Canvas(bitmap)
|
||||
canvas.drawText(areaString, 0f, Math.abs(fontMetrics.ascent), textPaint)
|
||||
val bitmap2: Bitmap = AndroidBitmap(bitmap)
|
||||
val markerSymbol = MarkerSymbol(bitmap2, MarkerSymbol.HotspotPlace.CENTER)
|
||||
mAreaLayer = ItemizedLayer(mMapView.vtmMap, ArrayList(), markerSymbol, null)
|
||||
mMapView.vtmMap.layers().add(mAreaLayer)
|
||||
canvas.drawText(areaString, 0f, abs(fontMetrics.ascent), textPaint)
|
||||
// val bitmap2: Bitmap = AndroidBitmap(bitmap)
|
||||
// val markerSymbol = MarkerSymbol(bitmap2, MarkerSymbol.HotspotPlace.CENTER)
|
||||
// mAreaLayer = ItemizedLayer(mMapView.vtmMap, ArrayList(), markerSymbol, null)
|
||||
// mMapView.vtmMap.layers().add(mAreaLayer)
|
||||
list.add(list[0])
|
||||
val polygon = GeometryTools.createPolygon(list)
|
||||
val point = polygon.centroid
|
||||
@@ -359,67 +361,149 @@ open class MeasureLayerHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
}
|
||||
}
|
||||
|
||||
open fun removeLine() {
|
||||
// bDrawLine = false
|
||||
// editIndex = -1
|
||||
// for (item in mPathMakers) {
|
||||
// mMapView.layerManager.removeMarker(item, NILayerManager.MARQUEE_MARKER_LAYER)
|
||||
// }
|
||||
// mPathMakers.clear()
|
||||
// if (mPathLayer != null) {
|
||||
// mPathLayer.clearPath()
|
||||
// mPathLayer.isEnabled = false
|
||||
// }
|
||||
// if (mPolygonLayer != null) {
|
||||
// mPolygonLayer.clearPath()
|
||||
// mPolygonLayer.isEnabled = false
|
||||
// }
|
||||
// if (mPathLayerTemp != null) {
|
||||
// mPathLayerTemp.clearPath()
|
||||
// mPathLayerTemp.isEnabled = false
|
||||
// mPathLayerTemp.setStyle(newTempStyle)
|
||||
// }
|
||||
/**
|
||||
* 清除所有
|
||||
*/
|
||||
fun clear() {
|
||||
bDrawLine = false
|
||||
editIndex = -1
|
||||
markerLayer.removeAllItems()
|
||||
mPathMakers.clear()
|
||||
mPathLayer.clearPath()
|
||||
mPathLayer.isEnabled = false
|
||||
mPolygonLayer.clearPath()
|
||||
mPolygonLayer.isEnabled = false
|
||||
mPathLayerTemp.clearPath()
|
||||
mPathLayerTemp.isEnabled = false
|
||||
mPathLayerTemp.setStyle(newTempStyle)
|
||||
hideAreaLayer()
|
||||
}
|
||||
|
||||
fun clean() {
|
||||
removeLine()
|
||||
lineLengthLiveData.value = 0.000
|
||||
tempLineDistanceLiveData.value = "0米"
|
||||
mMapView.vtmMap.updateMap(true)
|
||||
}
|
||||
|
||||
override fun onMapEvent(e: Event?, mapPosition: MapPosition?) {
|
||||
|
||||
override fun onMapEvent(e: Event, mapPosition: MapPosition) {
|
||||
if (!bDrawLine) return
|
||||
// if (mMapView.centerPixel[1] > mMapView.vtmMap.height / 2) {
|
||||
// val geoPoint =
|
||||
// mMapView.vtmMap.viewport()
|
||||
// .fromScreenPoint(
|
||||
// mMapView.centerPixel[0],
|
||||
// mMapView.vtmMap.height - mMapView.centerPixel[1]
|
||||
// )
|
||||
// mapPosition.setPosition(geoPoint)
|
||||
// }
|
||||
if (e === Map.POSITION_EVENT) {
|
||||
if (mPathLayer.points.size > 0) {
|
||||
if (editIndex > -1) {
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
if (editIndex == 0 || editIndex == mPathMakers.size - 1) {
|
||||
list.add(mPathMakers[editIndex].geoPoint)
|
||||
list.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
} else {
|
||||
list.add(mPathMakers[editIndex - 1].geoPoint)
|
||||
list.add(
|
||||
GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
)
|
||||
list.add(mPathMakers[editIndex + 1].geoPoint)
|
||||
}
|
||||
mPathLayerTemp.setPoints(list)
|
||||
// crossText.setText("")
|
||||
} else {
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
list.add(mPathLayer.points[mPathLayer.points.size - 1])
|
||||
val nowPoint = GeoPoint(
|
||||
mapPosition.latitude, mapPosition.longitude
|
||||
)
|
||||
list.add(
|
||||
nowPoint
|
||||
)
|
||||
mPathLayerTemp.setPoints(list)
|
||||
if (mPathLayer.points.size > 0) {
|
||||
val dList = mPathLayer.points.toMutableList()
|
||||
dList.add(nowPoint)
|
||||
val distance: Double =
|
||||
GeometryTools.getDistance(dList)
|
||||
if (distance < 1000) {
|
||||
tempLineDistanceLiveData.value = "${distance.toInt()}米"
|
||||
} else {
|
||||
try {
|
||||
val d = distance / 1000.0
|
||||
val bg = BigDecimal(d)
|
||||
val f1 =
|
||||
bg.setScale(1, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
tempLineDistanceLiveData.value = "${f1}公里"
|
||||
} catch (e: Exception) {
|
||||
Log.e("jingo", e.toString() + "$distance")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
tempLineDistanceLiveData.value = "0米"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private val itemGestureListener: OnItemGestureListener<*> =
|
||||
/**
|
||||
* 初始化线数据, 用来二次编辑
|
||||
*/
|
||||
fun initPathLine(geometry: String) {
|
||||
bDrawLine = true
|
||||
mPathLayer.isEnabled = true
|
||||
mPathLayerTemp.isEnabled = true
|
||||
val pointList = GeometryTools.getGeoPoints(geometry)
|
||||
mPathLayer.setPoints(pointList)
|
||||
for (point in pointList) {
|
||||
val markerItem = MarkerItem(createUUID(), "", "", point)
|
||||
markerLayer.addItem(markerItem)
|
||||
mPathMakers.add(markerItem)
|
||||
}
|
||||
if (mPathLayer.points.size > 1) {
|
||||
val distance: Double = GeometryTools.getDistance(mPathLayer.points)
|
||||
val bg = BigDecimal(distance)
|
||||
val f1 = bg.setScale(3, BigDecimal.ROUND_HALF_UP).toDouble()
|
||||
lineLengthLiveData.value = f1
|
||||
tempLineDistanceLiveData.value = "${f1}米"
|
||||
} else {
|
||||
lineLengthLiveData.value = 0.000
|
||||
}
|
||||
mMapView.updateMap(true)
|
||||
}
|
||||
|
||||
private val itemGestureListener: OnItemGestureListener<MarkerInterface> =
|
||||
object : OnItemGestureListener<MarkerInterface> {
|
||||
override fun onItemSingleTapUp(index: Int, item: MarkerInterface): Boolean {
|
||||
if (bDrawLine) {
|
||||
// for (i in mPathMakers.indices) {
|
||||
// val item1 = mPathMakers[i]
|
||||
// if (item === item1) {
|
||||
// mMapView.layerManager.jumpToPosition(
|
||||
// item.getPoint().longitude,
|
||||
// item.getPoint().latitude,
|
||||
// 0
|
||||
// )
|
||||
// editIndex = i
|
||||
// if (mPathLayerTemp != null) {
|
||||
// mPathLayerTemp.setStyle(editTempStyle)
|
||||
// val list: MutableList<GeoPoint> = java.util.ArrayList<GeoPoint>()
|
||||
// if (editIndex == 0 || editIndex == mPathMakers.size - 1) {
|
||||
// list.add(item.geoPoint as Nothing)
|
||||
// list.add(item.geoPoint as Nothing)
|
||||
// } else {
|
||||
// list.add(mPathMakers[editIndex - 1].geoPoint as Nothing)
|
||||
// list.add(item.geoPoint as Nothing)
|
||||
// list.add(mPathMakers[editIndex + 1].geoPoint as Nothing)
|
||||
// }
|
||||
// mPathLayerTemp.setPoints(list)
|
||||
// }
|
||||
// return true
|
||||
// }
|
||||
// }
|
||||
for (i in mPathMakers.indices) {
|
||||
val item1 = mPathMakers[i]
|
||||
if (item === item1) {
|
||||
mMapView.vtmMap.animator().animateTo(
|
||||
GeoPoint(
|
||||
item.getPoint().latitude, item.getPoint().longitude
|
||||
)
|
||||
)
|
||||
editIndex = i
|
||||
mPathLayerTemp.setStyle(editTempStyle)
|
||||
val list: MutableList<GeoPoint> = mutableListOf()
|
||||
if (editIndex == 0 || editIndex == mPathMakers.size - 1) {
|
||||
list.add(item.getPoint())
|
||||
list.add(item.getPoint())
|
||||
} else {
|
||||
list.add(mPathMakers[editIndex - 1].geoPoint)
|
||||
list.add(item.getPoint())
|
||||
list.add(mPathMakers[editIndex + 1].geoPoint)
|
||||
}
|
||||
mPathLayerTemp.setPoints(list)
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
package com.navinfo.collect.library.map.handler
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.Point
|
||||
import androidx.appcompat.app.AppCompatActivity
|
||||
import com.navinfo.collect.library.map.NIMapView
|
||||
import com.navinfo.collect.library.utils.GeometryTools
|
||||
import org.oscim.core.GeoPoint
|
||||
import org.oscim.core.Point
|
||||
|
||||
open class ViewportHandler(context: AppCompatActivity, mapView: NIMapView) : BaseHandler(context, mapView) {
|
||||
open class ViewportHandler(context: AppCompatActivity, mapView: NIMapView) :
|
||||
BaseHandler(context, mapView) {
|
||||
/**
|
||||
* Set pivot horizontal / vertical relative to view center in [-1, 1].
|
||||
* e.g. pivotY 0.5 is usually preferred for navigation, moving center to 25% of view height.
|
||||
@@ -54,32 +54,47 @@ open class ViewportHandler(context: AppCompatActivity, mapView: NIMapView) : Bas
|
||||
* @param snapType 扩展外接矩形的方式,用屏幕像素还是距离
|
||||
* @param distance 距离大小 像素 或 米
|
||||
*/
|
||||
// fun toScreenPoint(
|
||||
// geoPoint: GeoPoint
|
||||
// ): String {
|
||||
// val point = Point()
|
||||
//
|
||||
// mMapView.vtmMap.viewport().toScreenPoint(geoPoint, false, point)
|
||||
//
|
||||
// return "${point.x},${point.y}"
|
||||
// }
|
||||
|
||||
fun toScreenPoint(
|
||||
geoPoint: GeoPoint
|
||||
): String {
|
||||
val point = Point()
|
||||
): Point {
|
||||
val point = org.oscim.core.Point()
|
||||
|
||||
mMapView.vtmMap.viewport().toScreenPoint(geoPoint, false, point)
|
||||
|
||||
return "${point.x},${point.y}"
|
||||
return Point(point.x.toInt(), point.y.toInt())
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取几何的外接矩形,返回矩形的左上,右下两个坐标
|
||||
* @param snapType 扩展外接矩形的方式,用屏幕像素还是距离
|
||||
* @param distance 距离大小 像素 或 米
|
||||
*/
|
||||
fun fromScreenPoint(
|
||||
px: Float, py: Float
|
||||
): Map<String, Any> {
|
||||
|
||||
val geo = mMapView.vtmMap.viewport().fromScreenPoint(px, py)
|
||||
// /**
|
||||
// * 获取几何的外接矩形,返回矩形的左上,右下两个坐标
|
||||
// * @param snapType 扩展外接矩形的方式,用屏幕像素还是距离
|
||||
// * @param distance 距离大小 像素 或 米
|
||||
// */
|
||||
// fun fromScreenPointMap(
|
||||
// px: Float, py: Float
|
||||
// ): Map<String, Any> {
|
||||
//
|
||||
// val geo = mMapView.vtmMap.viewport().fromScreenPoint(px, py)
|
||||
//
|
||||
// return mapOf(
|
||||
// "latitude" to geo.latitude,
|
||||
// "longitude" to geo.longitude,
|
||||
// "longitudeE6" to geo.longitudeE6,
|
||||
// "latitudeE6" to geo.latitudeE6,
|
||||
// )
|
||||
// }
|
||||
|
||||
return mapOf(
|
||||
"latitude" to geo.latitude,
|
||||
"longitude" to geo.longitude,
|
||||
"longitudeE6" to geo.longitudeE6,
|
||||
"latitudeE6" to geo.latitudeE6,
|
||||
)
|
||||
fun fromScreenPoint(point: android.graphics.Point): GeoPoint {
|
||||
return mMapView.vtmMap.viewport().fromScreenPoint(point.x.toFloat(), point.y.toFloat())
|
||||
}
|
||||
}
|
||||
@@ -115,10 +115,13 @@ public class MyItemizedLayer extends ItemizedLayer {
|
||||
// it = this.mMarkerRenderer.mDefaultMarker;
|
||||
}
|
||||
|
||||
if (it.isInside(dx, dy)) {// && this.mTmpPoint.y > insideY) {
|
||||
// insideY = this.mTmpPoint.y;
|
||||
inside = i;
|
||||
list.add(i);
|
||||
try{
|
||||
if (it.isInside(dx, dy)) {
|
||||
inside = i;
|
||||
list.add(i);
|
||||
}
|
||||
}catch (Exception e){
|
||||
|
||||
}
|
||||
|
||||
if (inside < 0) {
|
||||
|
||||
@@ -0,0 +1,98 @@
|
||||
package com.navinfo.collect.library.map.layers
|
||||
|
||||
import android.graphics.Color
|
||||
import com.navinfo.collect.library.data.entity.NoteBean
|
||||
import com.navinfo.collect.library.utils.GeometryTools
|
||||
import org.oscim.layers.vector.VectorLayer
|
||||
import org.oscim.layers.vector.geometries.Drawable
|
||||
import org.oscim.layers.vector.geometries.LineDrawable
|
||||
import org.oscim.layers.vector.geometries.Style
|
||||
import org.oscim.map.Map
|
||||
|
||||
|
||||
class NoteLineLayer(map: Map) : VectorLayer(map) {
|
||||
private val lineMap = HashMap<String, MutableList<Drawable>>()
|
||||
|
||||
|
||||
private var selectDrawable: Drawable? = null
|
||||
|
||||
private val selectStyle =
|
||||
Style.builder().fillColor(Color.GREEN).strokeColor(Color.GREEN)
|
||||
.strokeWidth(10f).fixed(false).build()
|
||||
|
||||
|
||||
@Synchronized
|
||||
fun showNoteBeanLines(noteBean: NoteBean) {
|
||||
removeNoteBeanLines(noteBean)
|
||||
val list = mutableListOf<Drawable>()
|
||||
for (item in noteBean.list) {
|
||||
val lineDrawable =
|
||||
LineDrawable(GeometryTools.createGeometry(item.geometry), getStyle(item.style))
|
||||
add(lineDrawable)
|
||||
list.add(lineDrawable)
|
||||
}
|
||||
lineMap[noteBean.id] = list
|
||||
update()
|
||||
}
|
||||
|
||||
|
||||
@Synchronized
|
||||
fun removeNoteBeanLines(noteBean: NoteBean) {
|
||||
if (lineMap.containsKey(noteBean.id)) {
|
||||
for (drawable in lineMap[noteBean.id]!!) {
|
||||
remove(drawable)
|
||||
}
|
||||
lineMap.remove(noteBean.id)
|
||||
}
|
||||
update()
|
||||
}
|
||||
|
||||
|
||||
private fun getStyle(style: String): Style {
|
||||
// if (style.startsWith("4")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.RAILWAY_LINE
|
||||
// } else if (style.startsWith("5")) {
|
||||
// if (style.contains("cde3ac")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.GREENLAND_LINE
|
||||
// } else if (style.contains("abcaff")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.WATER_LINE
|
||||
// } else if (style.contains("fffe98")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.PARKING_LINE
|
||||
// }
|
||||
// } else {
|
||||
// val s: String = style.substring(0, 1)
|
||||
// if (TextUtils.equals(s, "2")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.STRAIGHT_LINE
|
||||
// } else if (TextUtils.equals(s, "3")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.RECT_LINE
|
||||
// } else if (TextUtils.equals(s, "6")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.POLY_LINE
|
||||
// } else if (TextUtils.equals(s, "7")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.ELLIPSE_LINE
|
||||
// } else if (TextUtils.equals(s, "9")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.CIRCULAR_POINT
|
||||
// } else if (TextUtils.equals(s, "1")) {
|
||||
// canvasStyle = CanvasView.CanvasStyle.FREE_LINE
|
||||
// }
|
||||
val width = style.substring(1, 3).toFloat()
|
||||
var colorStr: String = style.substring(3, style.length)
|
||||
colorStr = if (colorStr.length == 6) {
|
||||
"#ff$colorStr"
|
||||
} else {
|
||||
"#ff000000"
|
||||
}
|
||||
// val color = colorStr.toLong(16).toInt()
|
||||
return Style.builder().fillColor(colorStr).fillAlpha(0.5f).strokeColor(colorStr)
|
||||
.strokeWidth(width).fixed(true).build()
|
||||
}
|
||||
|
||||
fun removeAll() {
|
||||
for ((_, value) in lineMap) {
|
||||
for (item in value) {
|
||||
remove(item)
|
||||
}
|
||||
}
|
||||
lineMap.clear()
|
||||
update()
|
||||
}
|
||||
}
|
||||
@@ -10,6 +10,7 @@ import org.locationtech.jts.geom.Geometry
|
||||
import org.oscim.layers.vector.VectorLayer
|
||||
import org.oscim.layers.vector.geometries.Drawable
|
||||
import org.oscim.layers.vector.geometries.LineDrawable
|
||||
import org.oscim.layers.vector.geometries.PointDrawable
|
||||
import org.oscim.layers.vector.geometries.Style
|
||||
import org.oscim.map.Map
|
||||
|
||||
@@ -58,12 +59,11 @@ class OmdbTaskLinkLayer(map: Map, private var style: Style) : VectorLayer(map) {
|
||||
update()
|
||||
}
|
||||
|
||||
fun removeLine(linkPid: String): Boolean {
|
||||
fun removeLine(linkPid: String) {
|
||||
if (lineMap.containsKey(linkPid)) {
|
||||
super.remove(lineMap[linkPid])
|
||||
lineMap.remove(linkPid)
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
fun removeLine(geometry: Geometry) {
|
||||
@@ -86,4 +86,5 @@ class OmdbTaskLinkLayer(map: Map, private var style: Style) : VectorLayer(map) {
|
||||
clearSelectLine()
|
||||
update()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ public class OMDBDataDecoder extends TileDecoder {
|
||||
}
|
||||
|
||||
@RequiresApi(api = Build.VERSION_CODES.N)
|
||||
public boolean decode(Tile tile, ITileDataSink sink, List<RenderEntity> listResult) {
|
||||
public boolean decode(int zoomLevel,Tile tile, ITileDataSink sink, List<RenderEntity> listResult) {
|
||||
mTileDataSink = sink;
|
||||
mTileScale = 1 << tile.zoomLevel;
|
||||
mTileX = tile.tileX / mTileScale;
|
||||
@@ -71,10 +71,11 @@ public class OMDBDataDecoder extends TileDecoder {
|
||||
listResult.stream().iterator().forEachRemaining(new Consumer<RenderEntity>() {
|
||||
@Override
|
||||
public void accept(RenderEntity renderEntity) {
|
||||
// Log.d("RealmDBTileDataSource", renderEntity.getGeometry());
|
||||
Map<String, Object> properties= new HashMap<>(renderEntity.getProperties().size());
|
||||
properties.putAll(renderEntity.getProperties());
|
||||
parseGeometry(renderEntity.getTable(), renderEntity.getWkt(), properties);
|
||||
if(zoomLevel>=renderEntity.getZoomMin()&&zoomLevel<=renderEntity.getZoomMax()){
|
||||
Map<String, Object> properties= new HashMap<>(renderEntity.getProperties().size());
|
||||
properties.putAll(renderEntity.getProperties());
|
||||
parseGeometry(renderEntity.getTable(), renderEntity.getWkt(), properties);
|
||||
}
|
||||
}
|
||||
});
|
||||
return true;
|
||||
|
||||
@@ -48,7 +48,7 @@ public class OMDBReferenceDataSource implements ITileDataSource {
|
||||
}
|
||||
List<ReferenceEntity> listResult = realmQuery/*.distinct("id")*/.findAll();
|
||||
if (!listResult.isEmpty()) {
|
||||
mThreadLocalDecoders.get().decode(tile, mapDataSink, listResult);
|
||||
mThreadLocalDecoders.get().decode(tile.zoomLevel,tile, mapDataSink, listResult);
|
||||
}
|
||||
mapDataSink.completed(QueryResult.SUCCESS);
|
||||
// Log.d("RealmDBTileDataSource", "tile:"+tile.getBoundingBox().toString());
|
||||
|
||||
@@ -60,7 +60,7 @@ public class OMDBReferenceDecoder extends TileDecoder {
|
||||
}
|
||||
|
||||
@RequiresApi(api = Build.VERSION_CODES.N)
|
||||
public boolean decode(Tile tile, ITileDataSink sink, List<ReferenceEntity> listResult) {
|
||||
public boolean decode(int mapLevel,Tile tile, ITileDataSink sink, List<ReferenceEntity> listResult) {
|
||||
mTileDataSink = sink;
|
||||
mTileScale = 1 << tile.zoomLevel;
|
||||
mTileX = tile.tileX / mTileScale;
|
||||
@@ -70,10 +70,11 @@ public class OMDBReferenceDecoder extends TileDecoder {
|
||||
listResult.stream().iterator().forEachRemaining(new Consumer<ReferenceEntity>() {
|
||||
@Override
|
||||
public void accept(ReferenceEntity renderEntity) {
|
||||
// Log.d("RealmDBTileDataSource", renderEntity.getGeometry());
|
||||
Map<String, Object> properties= new HashMap<>(renderEntity.getProperties().size());
|
||||
properties.putAll(renderEntity.getProperties());
|
||||
parseGeometry(renderEntity.getTable(), renderEntity.getWkt(), properties);
|
||||
if(mapLevel>=renderEntity.getZoomMin()&&mapLevel<=renderEntity.getZoomMax()){
|
||||
Map<String, Object> properties= new HashMap<>(renderEntity.getProperties().size());
|
||||
properties.putAll(renderEntity.getProperties());
|
||||
parseGeometry(renderEntity.getTable(), renderEntity.getWkt(), properties);
|
||||
}
|
||||
}
|
||||
});
|
||||
return true;
|
||||
|
||||
@@ -50,7 +50,8 @@ public class OMDBTileDataSource implements ITileDataSource {
|
||||
}
|
||||
List<RenderEntity> listResult = realmQuery/*.distinct("id")*/.findAll();
|
||||
if (!listResult.isEmpty()) {
|
||||
mThreadLocalDecoders.get().decode(tile, mapDataSink, listResult);
|
||||
Log.e("qj","查询数据=="+listResult.size()+"==地图级别"+tile.zoomLevel);
|
||||
mThreadLocalDecoders.get().decode(tile.zoomLevel,tile, mapDataSink, listResult);
|
||||
}
|
||||
mapDataSink.completed(QueryResult.SUCCESS);
|
||||
// Log.d("RealmDBTileDataSource", "tile:"+tile.getBoundingBox().toString());
|
||||
|
||||
@@ -30,7 +30,7 @@ public class Constant {
|
||||
}
|
||||
public static String[] HAD_LAYER_INVISIABLE_ARRAY;
|
||||
public static final int OVER_ZOOM = 21;
|
||||
public static final int MAX_ZOOM = 25;
|
||||
public static final int MAX_ZOOM = 23;
|
||||
public static final int OMDB_MIN_ZOOM = 18;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1327,9 +1327,9 @@ public class GeometryTools {
|
||||
}
|
||||
|
||||
public static boolean isCheckError(double lon, double lat) {
|
||||
/* if(lon==0&&lat==0){
|
||||
if(lon==0||lat==0){
|
||||
return true;
|
||||
}*/
|
||||
}
|
||||
|
||||
if (lon > 180 || lon < -180 || lat > 90 || lat < -90) {
|
||||
return true;
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
package com.navinfo.collect.library.utils
|
||||
|
||||
import java.text.ParsePosition
|
||||
import java.text.SimpleDateFormat
|
||||
import java.util.*
|
||||
|
||||
|
||||
12
collect-library/src/main/res/drawable/icon_note_marker.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="54.723"
|
||||
android:viewportHeight="40">
|
||||
<path
|
||||
android:pathData="M7.442,28.743S26.236,7.002 42.58,4.502C23.513,11.5 1.721,39.987 1.721,39.987L22.968,39.987a1.589,1.589 0,0 0,-1.631 -1L4.445,38.987A78.915,78.915 0,0 1,10.438 33.243c10.9,-0.5 20.43,-1.5 26.968,-10 1.089,-2 -0.815,-1.749 -1.362,-1.749 5.176,-2 16.344,-9.495 14.709,-13.245 -0.815,-0.748 -1.362,-0.251 -1.362,-0.251s8.444,-5 4.077,-7.247S38.214,2.003 38.214,2.003s0.815,-1.5 -1.631,-1.5A31.679,31.679 0,0 0,20.521 7.002s0,-2 -1.362,-1.249C0.359,16.497 7.442,28.743 7.442,28.743Z"
|
||||
android:fillColor="#EA6B00"/>
|
||||
<path
|
||||
android:pathData="M4.6,35.624a2.016,2.016 0,0 0,-1.157 -0.481,2.3 2.3,0 0,0 -1.19,0.164 4.085,4.085 0,0 0,-1.3 1.189,4.031 4.031,0 0,0 -0.8,1.174s-0.478,1.749 0.229,2.1a3.616,3.616 0,0 0,2.484 0.067,4.594 4.594,0 0,0 1.373,-0.5 2.832,2.832 0,0 0,0.973 -0.978A2.291,2.291 0,0 0,4.6 35.624Z"
|
||||
android:fillColor="#EA6B00"/>
|
||||
</vector>
|
||||
BIN
collect-library/src/main/res/mipmap-hdpi/icon_gps.png
Normal file
|
After Width: | Height: | Size: 401 B |
BIN
collect-library/src/main/res/mipmap-hdpi/icon_gps_1.png
Normal file
|
After Width: | Height: | Size: 377 B |
BIN
collect-library/src/main/res/mipmap-hdpi/icon_nilocation.png
Normal file
|
After Width: | Height: | Size: 492 B |
BIN
collect-library/src/main/res/mipmap-hdpi/icon_nilocation_1.png
Normal file
|
After Width: | Height: | Size: 611 B |
BIN
collect-library/src/main/res/raw/icon_task_link_marker.png
Normal file
|
After Width: | Height: | Size: 4.6 KiB |