Merge branch 'dev_robo_240612_6.5.0_tmp' of gitlab.zhidaoauto.com:SCA/L4HA/AndroidApp/MoGoEagleEye into dev_robo_240612_6.5.0_tmp
This commit is contained in:
@@ -195,7 +195,7 @@
|
||||
|
||||
<!-- 前方路况探查 -->
|
||||
<com.mogo.eagle.core.function.view.RoadCrossRoamView
|
||||
android:layout_width="@dimen/dp_660"
|
||||
android:layout_width="@dimen/dp_670"
|
||||
android:layout_height="@dimen/dp_790"
|
||||
android:layout_marginTop="@dimen/dp_482"
|
||||
android:visibility="gone"
|
||||
|
||||
@@ -44,7 +44,6 @@ import mogo.telematics.pad.MessagePad.TrackedObject
|
||||
import mogo.v2x.MogoV2X
|
||||
import mogo.v2x.MogoV2X.RSI_PB
|
||||
import mogo.v2x.MogoV2X.RTEData_PB
|
||||
import java.lang.Math.abs
|
||||
import java.util.concurrent.TimeUnit.SECONDS
|
||||
|
||||
/**
|
||||
@@ -200,7 +199,7 @@ internal object V2NIdentifyDrawer {
|
||||
}
|
||||
}
|
||||
val alert = sb.toString()
|
||||
CallerRoadV2NEventWindowListenerManager.show("${itx.longitude}-${itx.latitude}", itx.systemTime.toLong(), EventTypeEnumNew.getMarker3DRes(poiType), alert, isDriver, itx.cameraIp, itx.longitude, itx.latitude)
|
||||
CallerRoadV2NEventWindowListenerManager.show("${itx.longitude}-${itx.latitude}", itx.systemTime.toLong(), EventTypeEnumNew.getUpdateIconRes(poiType), alert, isDriver, itx.cameraIp, itx.longitude, itx.latitude)
|
||||
}
|
||||
}
|
||||
//消息埋点
|
||||
@@ -296,13 +295,13 @@ internal object V2NIdentifyDrawer {
|
||||
override fun onShow() {
|
||||
super.onShow()
|
||||
runCatching { CallerHmiManager.notifyXiaoZhiStatusChanged(V2N(EventTypeEnumNew.getEnumType(poiType)), State.START) }
|
||||
CallerVisualAngleManager.changeAngle(RoadEvent(2, SECONDS))
|
||||
CallerVisualAngleManager.changeScene(RoadEvent(2, SECONDS))
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
super.onDismiss()
|
||||
runCatching { CallerHmiManager.notifyXiaoZhiStatusChanged(V2N(EventTypeEnumNew.getEnumType(poiType)), State.STOP) }
|
||||
CallerVisualAngleManager.changeAngle(Default())
|
||||
CallerVisualAngleManager.changeScene(Default())
|
||||
}
|
||||
},
|
||||
ALERT_WARNING_TOP,
|
||||
|
||||
@@ -91,7 +91,7 @@ class AiRoadMarker {
|
||||
marker.entity?.apply { roadMarker.drawMarkers(this, wrapper) }
|
||||
}
|
||||
if (drawRoadLine) {
|
||||
//施工中心点前方的自车行驶方向上300米距离
|
||||
/* //施工中心点前方的自车行驶方向上300米距离
|
||||
var l1: CenterLine? = null
|
||||
var l2: CenterLine? = null
|
||||
mogoMapData.get()?.getCenterLineRangeInfo(
|
||||
@@ -118,7 +118,7 @@ class AiRoadMarker {
|
||||
}
|
||||
countDown.incrementAndGet()
|
||||
realMark(marker, wrapper, l1, l2, location.heading)
|
||||
})
|
||||
})*/
|
||||
} else {
|
||||
wrapper.onRemoved = { id ->
|
||||
aiMakers.remove(id)
|
||||
|
||||
@@ -52,9 +52,25 @@ class V2XAiRoadEventMarker {
|
||||
builder.setMaxIndex(800000f)
|
||||
builder.setVisible(true)
|
||||
val line = CallerMapUIServiceManager.getOverlayManager()?.showOrUpdateLine(builder.build())
|
||||
|
||||
|
||||
// val colors2 = ArrayList<Int>()
|
||||
// colors2.add(Color.argb(204, 237, 172, 21))
|
||||
// colors2.add(Color.argb(0, 255, 255, 255))
|
||||
// builder2.colors(colors2)
|
||||
// builder2.points(points)
|
||||
// builder2.setIsGradient(true)
|
||||
// builder2.isFilledIn(true)
|
||||
// builder2.useFacade(false)
|
||||
// builder2.setUseGps(true)
|
||||
// builder2.setWidth(10f)
|
||||
//// builder2.setMaxIndex(800000f)
|
||||
// builder2.setVisible(true)
|
||||
// val line2 = CallerMapUIServiceManager.getOverlayManager()?.showOrUpdateLine(builder2.build())
|
||||
line?.let {
|
||||
current.set(Pair(line, wrapper.markers))
|
||||
wrapper.addLine(line)
|
||||
// wrapper.addLine(line2!!)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
package com.mogo.eagle.function.biz.v2x.v2n.scenario.scene.road;
|
||||
|
||||
import android.telecom.Call;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.eagle.core.data.enums.CommunicationType;
|
||||
import com.mogo.eagle.core.data.enums.DataSourceType;
|
||||
import com.mogo.eagle.core.data.enums.EventTypeEnumNew;
|
||||
@@ -171,7 +168,7 @@ public class V2XRoadEventScenario extends AbsV2XScenario<V2XRoadEventEntity> imp
|
||||
if (isNeedChangeAngle()) {
|
||||
MarkerLocation location = content.getLocation();
|
||||
if (location != null) {
|
||||
CallerVisualAngleManager.INSTANCE.changeAngle(new RoadEvent(2, TimeUnit.SECONDS));
|
||||
CallerVisualAngleManager.INSTANCE.changeScene(new RoadEvent(2, TimeUnit.SECONDS));
|
||||
}
|
||||
}
|
||||
if (entity.isNeedAddLine() && !EventTypeEnumNew.TYPE_SOCKET_ROAD_CONGESTION.getPoiType().equals(content.getPoiType())) {
|
||||
@@ -202,7 +199,7 @@ public class V2XRoadEventScenario extends AbsV2XScenario<V2XRoadEventEntity> imp
|
||||
} catch (Throwable ignore) {}
|
||||
}
|
||||
}
|
||||
CallerVisualAngleManager.INSTANCE.changeAngle(new Default(3, TimeUnit.SECONDS));
|
||||
CallerVisualAngleManager.INSTANCE.changeScene(new Default(3, TimeUnit.SECONDS));
|
||||
}
|
||||
release();
|
||||
}
|
||||
|
||||
@@ -417,12 +417,12 @@ class MogoObuDcCombineManager private constructor() : IMoGoObuWarningRsiListener
|
||||
showWarning(v2xType, alertContent, ttsContent, direction, object : IMoGoWarningStatusListener {
|
||||
|
||||
override fun onShow() {
|
||||
CallerVisualAngleManager.changeAngle(CrossRoad(2))
|
||||
CallerVisualAngleManager.changeScene(CrossRoad(2))
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
super.onDismiss()
|
||||
CallerVisualAngleManager.changeAngle(Default())
|
||||
CallerVisualAngleManager.changeScene(Default())
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -9,7 +9,6 @@ import com.mogo.eagle.core.data.obu.MogoObuConst
|
||||
import com.mogo.eagle.core.function.angle.scenes.CrossRoad
|
||||
import com.mogo.eagle.core.function.angle.scenes.Default
|
||||
import com.mogo.eagle.core.function.api.hmi.warning.IMoGoWarningStatusListener
|
||||
import com.mogo.eagle.core.function.api.map.angle.*
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationGCJ02ListenerManager
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager
|
||||
@@ -968,14 +967,14 @@ class MogoPrivateObuNewManager private constructor() : OnUpgradeListener {
|
||||
override fun onShow() {
|
||||
if (appId == MogoObuShowConstants.V2X_WARNING_TYPE.BSW.toString()) {
|
||||
//盲区预警,展示近视角
|
||||
CallerVisualAngleManager.changeAngle(CrossRoad(2))
|
||||
CallerVisualAngleManager.changeScene(CrossRoad(2))
|
||||
}
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
if (appId == MogoObuShowConstants.V2X_WARNING_TYPE.BSW.toString()) {
|
||||
//盲区预警,取消近视角
|
||||
CallerVisualAngleManager.changeAngle(Default())
|
||||
CallerVisualAngleManager.changeScene(Default())
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -2,34 +2,54 @@ package com.mogo.eagle.core.function.hmi.ui.widget
|
||||
|
||||
import android.app.Dialog
|
||||
import android.content.Context
|
||||
import android.view.LayoutInflater
|
||||
import androidx.lifecycle.LifecycleObserver
|
||||
import android.os.Bundle
|
||||
import android.widget.ImageView
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.dialog.BaseFloatDialog
|
||||
import me.jessyan.autosize.utils.AutoSizeUtils
|
||||
|
||||
/**
|
||||
* 行程总结View
|
||||
* 鹰眼6.5.0需求
|
||||
*/
|
||||
class ItinerarySummaryDialog(context: Context) : BaseFloatDialog(context), LifecycleObserver {
|
||||
class ItinerarySummaryDialog(context: Context, isDriver: Boolean, theme: Int) :
|
||||
Dialog(context, theme) {
|
||||
|
||||
companion object {
|
||||
private const val TAG = "ItinerarySummaryView"
|
||||
private val mContext: Context
|
||||
private val isDriver: Boolean
|
||||
|
||||
|
||||
|
||||
}
|
||||
private var ivSummaryClose: ImageView ?= null
|
||||
|
||||
init {
|
||||
setContentView(R.layout.dialog_itinerary_summary)
|
||||
this.mContext = context
|
||||
this.isDriver = isDriver
|
||||
}
|
||||
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
override fun onCreate(savedInstanceState: Bundle?){
|
||||
super.onCreate(savedInstanceState)
|
||||
val params = window!!.attributes
|
||||
if(isDriver){
|
||||
setContentView(R.layout.dialog_itinerary_summary)
|
||||
params.height = AutoSizeUtils.dp2px(context,840f)
|
||||
params.width = AutoSizeUtils.dp2px(context,1600f)
|
||||
}else{
|
||||
setContentView(R.layout.dialog_itinerary_summary_p)
|
||||
params.height = AutoSizeUtils.dp2px(context,1170f)
|
||||
params.width = AutoSizeUtils.dp2px(context,2158f)
|
||||
}
|
||||
window!!.attributes = params //向WindowManager设置属性
|
||||
setCanceledOnTouchOutside(false)
|
||||
initEvent()
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
private fun initEvent(){
|
||||
//关闭Dialog按钮
|
||||
ivSummaryClose = findViewById(R.id.ivSummaryClose)
|
||||
ivSummaryClose?.setOnClickListener {
|
||||
dismiss()
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
Before Width: | Height: | Size: 2.2 MiB After Width: | Height: | Size: 2.2 MiB |
Binary file not shown.
|
Before Width: | Height: | Size: 6.3 KiB After Width: | Height: | Size: 1.5 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 6.3 KiB |
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_16"/>
|
||||
<solid android:color="#121826" />
|
||||
|
||||
</shape>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_20"/>
|
||||
<solid android:color="#333E52" />
|
||||
|
||||
</shape>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle">
|
||||
<gradient
|
||||
android:startColor="#2B61A5FF"
|
||||
android:endColor="#2B6F9EFB"/>
|
||||
<corners
|
||||
android:radius="@dimen/dp_25"/>
|
||||
</shape>
|
||||
@@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<solid android:color="#121826" />
|
||||
<corners android:radius="@dimen/dp_20"
|
||||
/>
|
||||
|
||||
<stroke
|
||||
android:width="@dimen/dp_2"
|
||||
android:color="#34425E" />
|
||||
|
||||
</shape>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_26"/>
|
||||
<solid android:color="#73FFFFFF" />
|
||||
|
||||
</shape>
|
||||
@@ -1,53 +1,56 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_2158"
|
||||
android:layout_height="@dimen/dp_1170"
|
||||
android:layout_width="@dimen/dp_1600"
|
||||
android:layout_height="@dimen/dp_840"
|
||||
android:background="@drawable/bg_itinerary_summary"
|
||||
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivSummaryClose"
|
||||
android:layout_width="@dimen/dp_86"
|
||||
android:layout_height="@dimen/dp_86"
|
||||
android:layout_width="@dimen/dp_50"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:src="@drawable/icon_summary_close"
|
||||
android:contentDescription="@string/summary_close"
|
||||
android:layout_marginEnd="@dimen/dp_43"
|
||||
android:layout_marginTop="@dimen/dp_68"
|
||||
android:layout_marginEnd="@dimen/dp_15"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivSummaryZhi"
|
||||
android:layout_width="@dimen/dp_190"
|
||||
android:layout_height="@dimen/dp_160"
|
||||
android:layout_width="@dimen/dp_135"
|
||||
android:layout_height="@dimen/dp_114"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:src="@drawable/icon_summary_zhi"
|
||||
android:contentDescription="@string/summary_zhi"
|
||||
android:layout_marginTop="@dimen/dp_120"
|
||||
android:layout_marginStart="@dimen/dp_735"
|
||||
android:layout_marginTop="@dimen/dp_98"
|
||||
android:layout_marginStart="@dimen/dp_565"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="@dimen/dp_927"
|
||||
android:layout_height="@dimen/dp_84"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_130"
|
||||
android:layout_marginEnd="@dimen/dp_220"
|
||||
android:layout_width="@dimen/dp_738"
|
||||
android:layout_height="@dimen/dp_60"
|
||||
app:layout_constraintTop_toTopOf="@id/ivSummaryZhi"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivSummaryZhi"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:layout_marginStart="@dimen/dp_20"
|
||||
android:background="@drawable/bg_summary_zhi_tip"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:gravity="center"
|
||||
android:text="全程 5km,智慧道路护航 3km,全息感知覆盖率 60%,车辆服务"
|
||||
/>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/clService"
|
||||
android:layout_width="@dimen/dp_1261"
|
||||
android:layout_height="@dimen/dp_260"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_486"
|
||||
android:layout_marginEnd="@dimen/dp_83"
|
||||
android:layout_width="@dimen/dp_970"
|
||||
android:layout_height="@dimen/dp_200"
|
||||
app:layout_constraintTop_toBottomOf="@id/ivSummaryZhi"
|
||||
app:layout_constraintLeft_toLeftOf="@id/ivSummaryZhi"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:background="@drawable/bg_summary_service"
|
||||
>
|
||||
|
||||
<TextView
|
||||
@@ -56,11 +59,11 @@
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:textColor="@color/summary_service_content"
|
||||
android:text="@string/summary_intersection_services"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginStart="@dimen/dp_58"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
android:layout_marginStart="@dimen/dp_39"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -70,10 +73,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvInfoTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:textColor="@color/summary_service_content"
|
||||
android:text="@string/summary_light_services"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -83,10 +86,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvLightServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVehicleTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:textColor="@color/summary_service_content"
|
||||
android:text="@string/summary_info_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -96,10 +99,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvInfoTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVulnerableTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:textColor="@color/summary_service_content"
|
||||
android:text="@string/summary_vehicle_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -108,11 +111,11 @@
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textSize="@dimen/sp_20"
|
||||
android:textColor="@color/summary_service_content"
|
||||
android:text="@string/summary_vulnerable_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginEnd="@dimen/dp_58"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
android:layout_marginEnd="@dimen/dp_39"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -122,9 +125,10 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvIntersectionServicesUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textSize="@dimen/sp_72"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="1"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -134,9 +138,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvIntersectionServicesNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvIntersectionServicesNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvIntersectionServices"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
@@ -147,9 +152,10 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvLightServices"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvLightServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvLightServicesUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textSize="@dimen/sp_72"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="4"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -159,9 +165,10 @@
|
||||
app:layout_constraintRight_toRightOf="@id/tvLightServices"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvLightServicesNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvLightServicesNum"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
@@ -172,9 +179,10 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvInfoTip"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvInfoTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvInfoTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textSize="@dimen/sp_72"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="3"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -184,9 +192,10 @@
|
||||
app:layout_constraintLeft_toRightOf="@id/tvInfoTipNum"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvInfoTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvInfoTip"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
@@ -197,9 +206,10 @@
|
||||
app:layout_constraintBottom_toTopOf="@id/tvVehicleTip"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvVehicleTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVehicleTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textSize="@dimen/sp_72"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="2"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -209,9 +219,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvVehicleTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvVehicleTip"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvVehicleTipNum"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
@@ -222,9 +233,11 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvVulnerableTip"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvVulnerableTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVulnerableTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textSize="@dimen/sp_72"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="5"
|
||||
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -234,9 +247,10 @@
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvVulnerableTipNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvVulnerableTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvVulnerableTip"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_service_num"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_15"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
@@ -244,11 +258,12 @@
|
||||
|
||||
<View
|
||||
android:id="@+id/viewDangerLayout"
|
||||
android:layout_width="@dimen/dp_611"
|
||||
android:layout_height="@dimen/dp_366"
|
||||
android:layout_width="@dimen/dp_470"
|
||||
android:layout_height="@dimen/dp_270"
|
||||
app:layout_constraintTop_toBottomOf="@id/clService"
|
||||
app:layout_constraintLeft_toLeftOf="@id/clService"
|
||||
android:layout_marginTop="@dimen/dp_38"
|
||||
android:background="@drawable/bg_summary_achievement"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -257,9 +272,10 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewDangerLayout"
|
||||
app:layout_constraintRight_toRightOf="@id/viewDangerLayout"
|
||||
app:layout_constraintTop_toTopOf="@id/viewDangerLayout"
|
||||
android:textSize="@dimen/sp_39"
|
||||
android:textColor="@color/summary_danger_title"
|
||||
android:textSize="@dimen/sp_30"
|
||||
android:textColor="@color/white"
|
||||
android:text="@string/summary_danger_title"
|
||||
android:layout_marginTop="@dimen/dp_44"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -271,7 +287,9 @@
|
||||
app:layout_constraintRight_toLeftOf="@id/tvDangerUnit"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:textColor="@color/summary_danger_num"
|
||||
android:textSize="@dimen/sp_195"
|
||||
android:textSize="@dimen/sp_150"
|
||||
android:text="5"
|
||||
android:layout_marginTop="@dimen/dp_80"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -282,18 +300,20 @@
|
||||
app:layout_constraintRight_toRightOf="@id/viewDangerLayout"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvDangerNum"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:textColor="@color/summary_danger_num"
|
||||
android:textSize="@dimen/sp_52"
|
||||
android:textSize="@dimen/sp_40"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<View
|
||||
android:id="@+id/viewEfficiencyLayout"
|
||||
android:layout_width="@dimen/dp_611"
|
||||
android:layout_height="@dimen/dp_366"
|
||||
android:layout_width="@dimen/dp_470"
|
||||
android:layout_height="@dimen/dp_270"
|
||||
app:layout_constraintTop_toBottomOf="@id/clService"
|
||||
app:layout_constraintRight_toRightOf="@id/clService"
|
||||
android:layout_marginTop="@dimen/dp_38"
|
||||
android:background="@drawable/bg_summary_achievement"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -303,8 +323,9 @@
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintTop_toTopOf="@id/viewEfficiencyLayout"
|
||||
android:text="@string/summary_efficiency_title"
|
||||
android:textSize="@dimen/sp_39"
|
||||
android:textColor="@color/summary_danger_title"
|
||||
android:textSize="@dimen/sp_30"
|
||||
android:textColor="@color/white"
|
||||
android:layout_marginTop="@dimen/dp_44"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -316,7 +337,9 @@
|
||||
app:layout_constraintRight_toLeftOf="@id/tvEfficiencyUnit"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:textColor="@color/summary_danger_num"
|
||||
android:textSize="@dimen/sp_195"
|
||||
android:textSize="@dimen/sp_150"
|
||||
android:text="13"
|
||||
android:layout_marginTop="@dimen/dp_80"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -327,7 +350,8 @@
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvEfficiencyNum"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:textSize="@dimen/sp_52"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:textSize="@dimen/sp_40"
|
||||
android:textColor="@color/summary_danger_num"
|
||||
android:text="@string/summary_efficiency_unit"
|
||||
/>
|
||||
@@ -338,8 +362,10 @@
|
||||
app:layout_constraintTop_toBottomOf="@id/viewDangerLayout"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewDangerLayout"
|
||||
android:text="@string/summary_danger_tip"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:textColor="@color/summary_tip"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
android:layout_marginStart="@dimen/dp_m_10"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -348,8 +374,9 @@
|
||||
app:layout_constraintTop_toBottomOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
android:text="@string/summary_powered"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textSize="@dimen/sp_16"
|
||||
android:textColor="@color/summary_tip"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,382 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_2158"
|
||||
android:layout_height="@dimen/dp_1170"
|
||||
android:background="@drawable/bg_itinerary_summary_p"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivSummaryClose"
|
||||
android:layout_width="@dimen/dp_86"
|
||||
android:layout_height="@dimen/dp_86"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:src="@drawable/icon_summary_close_p"
|
||||
android:contentDescription="@string/summary_close"
|
||||
android:layout_marginEnd="@dimen/dp_80"
|
||||
android:layout_marginTop="@dimen/dp_80"
|
||||
/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivSummaryZhi"
|
||||
android:layout_width="@dimen/dp_190"
|
||||
android:layout_height="@dimen/dp_160"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:src="@drawable/icon_summary_zhi"
|
||||
android:contentDescription="@string/summary_zhi"
|
||||
android:layout_marginTop="@dimen/dp_150"
|
||||
android:layout_marginStart="@dimen/dp_813"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="@dimen/dp_927"
|
||||
android:layout_height="@dimen/dp_84"
|
||||
app:layout_constraintTop_toTopOf="@id/ivSummaryZhi"
|
||||
app:layout_constraintLeft_toRightOf="@id/ivSummaryZhi"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:layout_marginStart="@dimen/dp_20"
|
||||
android:background="@drawable/bg_summary_zhi_tip"
|
||||
android:textColor="@color/black"
|
||||
android:textSize="@dimen/sp_28"
|
||||
android:gravity="center"
|
||||
android:text="“旅途全长 38 km,全感知覆盖率 90%,车辆服务次数 68次”"
|
||||
/>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/clService"
|
||||
android:layout_width="@dimen/dp_1261"
|
||||
android:layout_height="@dimen/dp_260"
|
||||
app:layout_constraintTop_toBottomOf="@id/ivSummaryZhi"
|
||||
app:layout_constraintLeft_toLeftOf="@id/ivSummaryZhi"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:background="@drawable/bg_summary_service_p"
|
||||
>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvIntersectionServices"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textColor="@color/summary_service_content_p"
|
||||
android:text="@string/summary_intersection_services"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginStart="@dimen/dp_58"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvLightServices"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvInfoTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textColor="@color/summary_service_content_p"
|
||||
android:text="@string/summary_light_services"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvInfoTip"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvLightServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVehicleTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textColor="@color/summary_service_content_p"
|
||||
android:text="@string/summary_info_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVehicleTip"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvInfoTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVulnerableTip"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textColor="@color/summary_service_content_p"
|
||||
android:text="@string/summary_vehicle_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVulnerableTip"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:textSize="@dimen/sp_26"
|
||||
android:textColor="@color/summary_service_content_p"
|
||||
android:text="@string/summary_vulnerable_tip"
|
||||
android:layout_marginBottom="@dimen/dp_56"
|
||||
android:layout_marginEnd="@dimen/dp_58"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvIntersectionServicesNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvIntersectionServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvIntersectionServicesUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="1"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvIntersectionServicesUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvIntersectionServicesNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvIntersectionServicesNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvIntersectionServices"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvLightServicesNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvLightServices"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvLightServices"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvLightServicesUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="4"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvLightServicesUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintRight_toRightOf="@id/tvLightServices"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvLightServicesNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvLightServicesNum"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvInfoTipNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvInfoTip"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvInfoTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvInfoTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="3"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvInfoTipUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvInfoTipNum"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvInfoTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvInfoTip"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVehicleTipNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvVehicleTip"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvVehicleTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVehicleTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="2"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVehicleTipUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvVehicleTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvVehicleTip"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvVehicleTipNum"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVulnerableTipNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvVulnerableTip"
|
||||
app:layout_constraintBottom_toTopOf="@id/tvVulnerableTip"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvVulnerableTipUnit"
|
||||
android:textSize="@dimen/sp_94"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:text="5"
|
||||
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvVulnerableTipUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvVulnerableTipNum"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvVulnerableTipNum"
|
||||
app:layout_constraintRight_toRightOf="@id/tvVulnerableTip"
|
||||
android:textSize="@dimen/sp_31"
|
||||
android:textColor="@color/summary_service_num_p"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<View
|
||||
android:id="@+id/viewDangerLayout"
|
||||
android:layout_width="@dimen/dp_611"
|
||||
android:layout_height="@dimen/dp_366"
|
||||
app:layout_constraintTop_toBottomOf="@id/clService"
|
||||
app:layout_constraintLeft_toLeftOf="@id/clService"
|
||||
android:layout_marginTop="@dimen/dp_38"
|
||||
android:background="@drawable/bg_summary_achievement_p"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewDangerLayout"
|
||||
app:layout_constraintRight_toRightOf="@id/viewDangerLayout"
|
||||
app:layout_constraintTop_toTopOf="@id/viewDangerLayout"
|
||||
android:textSize="@dimen/sp_39"
|
||||
android:textColor="@color/summary_danger_title"
|
||||
android:text="@string/summary_danger_title"
|
||||
android:layout_marginTop="@dimen/dp_58"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDangerNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/viewDangerLayout"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewDangerLayout"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvDangerUnit"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:textColor="@color/summary_danger_num_p"
|
||||
android:textSize="@dimen/sp_195"
|
||||
android:text="5"
|
||||
android:layout_marginTop="@dimen/dp_120"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDangerUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvDangerNum"
|
||||
app:layout_constraintRight_toRightOf="@id/viewDangerLayout"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvDangerNum"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:textColor="@color/summary_danger_num_p"
|
||||
android:textSize="@dimen/sp_52"
|
||||
android:text="@string/summary_service_unit"
|
||||
/>
|
||||
|
||||
<View
|
||||
android:id="@+id/viewEfficiencyLayout"
|
||||
android:layout_width="@dimen/dp_611"
|
||||
android:layout_height="@dimen/dp_366"
|
||||
app:layout_constraintTop_toBottomOf="@id/clService"
|
||||
app:layout_constraintRight_toRightOf="@id/clService"
|
||||
android:layout_marginTop="@dimen/dp_38"
|
||||
android:background="@drawable/bg_summary_achievement_p"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintTop_toTopOf="@id/viewEfficiencyLayout"
|
||||
android:text="@string/summary_efficiency_title"
|
||||
android:textSize="@dimen/sp_39"
|
||||
android:textColor="@color/summary_danger_title"
|
||||
android:layout_marginTop="@dimen/dp_58"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvEfficiencyNum"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintRight_toLeftOf="@id/tvEfficiencyUnit"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:textColor="@color/summary_danger_num_p"
|
||||
android:textSize="@dimen/sp_195"
|
||||
android:text="13"
|
||||
android:layout_marginTop="@dimen/dp_120"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvEfficiencyUnit"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toBottomOf="@id/tvEfficiencyNum"
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintLeft_toRightOf="@id/tvEfficiencyNum"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:textSize="@dimen/sp_52"
|
||||
android:textColor="@color/summary_danger_num_p"
|
||||
android:text="@string/summary_efficiency_unit"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/viewDangerLayout"
|
||||
app:layout_constraintLeft_toLeftOf="@id/viewDangerLayout"
|
||||
android:text="@string/summary_danger_tip"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_tip_p"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
android:layout_marginStart="@dimen/dp_m_10"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/viewEfficiencyLayout"
|
||||
app:layout_constraintRight_toRightOf="@id/viewEfficiencyLayout"
|
||||
android:text="@string/summary_powered"
|
||||
android:textSize="@dimen/sp_24"
|
||||
android:textColor="@color/summary_tip_p"
|
||||
android:layout_marginTop="@dimen/dp_15"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -3,7 +3,8 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_margin="@dimen/dp_10"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
>
|
||||
|
||||
<ImageView
|
||||
@@ -12,6 +13,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/icon_exploration_loading"
|
||||
android:contentDescription="@string/exploration_loading"
|
||||
android:layout_gravity="center_vertical"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -21,6 +23,7 @@
|
||||
android:textSize="@dimen/sp_18"
|
||||
android:textColor="@color/white"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
android:layout_gravity="center_vertical"
|
||||
/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -3,7 +3,8 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_margin="@dimen/dp_10">
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_10">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivExplorationLoading"
|
||||
@@ -11,6 +12,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/icon_exploration_loading_p"
|
||||
android:contentDescription="@string/exploration_loading"
|
||||
android:layout_gravity="center_vertical"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
@@ -20,6 +22,7 @@
|
||||
android:textSize="@dimen/sp_18"
|
||||
android:textColor="@color/auto_exploration_content_p"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
android:layout_gravity="center_vertical"
|
||||
/>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -7,8 +7,8 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivScan"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="@dimen/dp_100"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:src="@drawable/icon_exploration_scan"
|
||||
@@ -17,8 +17,8 @@
|
||||
/>
|
||||
|
||||
<ImageView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="@dimen/dp_75"
|
||||
android:layout_height="@dimen/dp_75"
|
||||
app:layout_constraintTop_toTopOf="@id/ivScan"
|
||||
app:layout_constraintBottom_toBottomOf="@id/ivScan"
|
||||
app:layout_constraintLeft_toLeftOf="@id/ivScan"
|
||||
@@ -38,7 +38,6 @@
|
||||
android:textColor="@color/white"
|
||||
android:text="@string/exploration_title"
|
||||
android:layout_marginStart="@dimen/dp_30"
|
||||
android:layout_marginTop="@dimen/dp_30"
|
||||
/>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
@@ -47,6 +46,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvExplorationTitle"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvExplorationTitle"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -47,7 +47,6 @@
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:src="@drawable/icon_exploration_close"
|
||||
android:contentDescription="@string/exploration_close"
|
||||
android:padding="@dimen/dp_20"
|
||||
/>
|
||||
|
||||
<androidx.recyclerview.widget.RecyclerView
|
||||
@@ -56,6 +55,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toBottomOf="@id/tvExplorationTitle"
|
||||
app:layout_constraintLeft_toLeftOf="@id/tvExplorationTitle"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -86,11 +86,15 @@
|
||||
<color name="voice_user_end">#FF1E32D9</color>
|
||||
<color name="voice_resp">#243959</color>
|
||||
|
||||
<color name="summary_service_content">#49546A</color>
|
||||
<color name="summary_service_num">#464646</color>
|
||||
<color name="summary_service_content">#7C93C2</color>
|
||||
<color name="summary_service_content_p">#49546A</color>
|
||||
<color name="summary_service_num">#FFFFFF</color>
|
||||
<color name="summary_service_num_p">#464646</color>
|
||||
<color name="summary_danger_title">#24313E</color>
|
||||
<color name="summary_danger_num">#106FF0</color>
|
||||
<color name="summary_tip">#42464F</color>
|
||||
<color name="summary_danger_num">#2DF0FE</color>
|
||||
<color name="summary_danger_num_p">#106FF0</color>
|
||||
<color name="summary_tip">#6A758D</color>
|
||||
<color name="summary_tip_p">#42464F</color>
|
||||
|
||||
<color name="light_prompt_content">#131415 </color>
|
||||
<color name="light_prompt_red">#FF3B2D</color>
|
||||
|
||||
@@ -88,4 +88,20 @@
|
||||
<item name="android:layout_margin">@dimen/dp_10</item>
|
||||
</style>
|
||||
|
||||
<style name="summary_dialog" parent="@android:style/Theme.Dialog">
|
||||
<item name="android:windowFrame">@null</item>
|
||||
<item name="android:windowNoTitle">true</item>
|
||||
<item name="android:windowBackground">@drawable/bg_itinerary_summary</item>
|
||||
<item name="android:windowIsFloating">true</item>
|
||||
<item name="android:windowContentOverlay">@null</item>
|
||||
</style>
|
||||
|
||||
<style name="summary_dialog_p" parent="@android:style/Theme.Dialog">
|
||||
<item name="android:windowFrame">@null</item>
|
||||
<item name="android:windowNoTitle">true</item>
|
||||
<item name="android:windowBackground">@drawable/bg_itinerary_summary_p</item>
|
||||
<item name="android:windowIsFloating">true</item>
|
||||
<item name="android:windowContentOverlay">@null</item>
|
||||
</style>
|
||||
|
||||
</resources>
|
||||
|
||||
@@ -71,7 +71,7 @@ class MoGoVisualAngleChangeProvider: IMoGoVisualAngleChangeProvider {
|
||||
}
|
||||
}
|
||||
if (triggerClose) {
|
||||
changeAngle(Default())
|
||||
changeScene(Default())
|
||||
}
|
||||
}
|
||||
|
||||
@@ -83,7 +83,7 @@ class MoGoVisualAngleChangeProvider: IMoGoVisualAngleChangeProvider {
|
||||
triggerRoadId.set(this.roadId.get())
|
||||
distanceOfCarToStopLine.set(info.distance)
|
||||
triggerLocation.set(CallerChassisLocationGCJ02ListenerManager.getChassisLocationGCJ02())
|
||||
changeAngle(CrossRoad(2))
|
||||
changeScene(CrossRoad(2))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -130,7 +130,7 @@ class MoGoVisualAngleChangeProvider: IMoGoVisualAngleChangeProvider {
|
||||
mLevel = level
|
||||
}
|
||||
|
||||
override fun changeAngle(scene: Scene) {
|
||||
override fun changeScene(scene: Scene) {
|
||||
if(mLevel){
|
||||
return
|
||||
}
|
||||
@@ -140,13 +140,21 @@ class MoGoVisualAngleChangeProvider: IMoGoVisualAngleChangeProvider {
|
||||
if (delay > 0) {
|
||||
delay(delay)
|
||||
}
|
||||
|
||||
val lastPriority = prevScene.get()?.priority ?: Int.MIN_VALUE
|
||||
val currentPriority = scene.priority
|
||||
if (lastPriority > currentPriority) {
|
||||
return@launch
|
||||
}
|
||||
doChangeAngle(scene)
|
||||
}.also {
|
||||
prevJob = it
|
||||
}
|
||||
}
|
||||
|
||||
override fun getCurrentScene(): Scene {
|
||||
return prevScene.get() ?: Default()
|
||||
}
|
||||
|
||||
private fun doChangeAngle(target: Scene) {
|
||||
val angle = target.angle
|
||||
CallerMapUIServiceManager.getMapUIController()?.also {
|
||||
@@ -159,6 +167,12 @@ class MoGoVisualAngleChangeProvider: IMoGoVisualAngleChangeProvider {
|
||||
notifyChanged(target)
|
||||
}
|
||||
prevScene.set(target)
|
||||
if (target.displayThreshold > 0) {
|
||||
scope.launch {
|
||||
delay(target.displayThreshold)
|
||||
doChangeAngle(Default(0))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ class CrossRoad(private val delayTime: Long): Scene {
|
||||
override val angle: VisualAngleMode
|
||||
get() = MAP_STYLE_VR_ANGLE_CROSS
|
||||
|
||||
override val priority: Int = 4
|
||||
override val priority: Int = 0
|
||||
override val displayThreshold: Long
|
||||
get() = -1
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ class Default(val delayTime: Long = 2, val unit: TimeUnit = TimeUnit.SECONDS): S
|
||||
override val angle: VisualAngleMode
|
||||
get() = CallerMapUIServiceManager.getMapUIController()?.getVrAngleDefaultMode() ?: MODE_MEDIUM_SIGHT
|
||||
|
||||
override val priority: Int = 1
|
||||
override val priority: Int = 0
|
||||
|
||||
override val displayThreshold: Long
|
||||
get() = 0
|
||||
|
||||
@@ -12,7 +12,7 @@ class LongSight(private val delayTime: Long, private val unit: TimeUnit = TimeUn
|
||||
override val priority: Int
|
||||
get() = 0
|
||||
override val displayThreshold: Long
|
||||
get() = 0
|
||||
get() = -1
|
||||
|
||||
override val delay: Long
|
||||
get() = unit.toMillis(delayTime)
|
||||
|
||||
@@ -13,10 +13,10 @@ class RoadEvent(private val delayTime: Long, private val unit: TimeUnit): Scene
|
||||
|
||||
override val angle: VisualAngleMode = CallerMapUIServiceManager.getMapUIController()?.getVrAngleDefaultMode() ?: MODE_MEDIUM_SIGHT
|
||||
|
||||
override val priority: Int = 5
|
||||
override val priority: Int = 0
|
||||
|
||||
override val displayThreshold: Long
|
||||
get() = TimeUnit.SECONDS.toMillis(8)
|
||||
get() = -1
|
||||
|
||||
override val delay: Long
|
||||
get() = unit.toMillis(delayTime)
|
||||
|
||||
@@ -9,10 +9,8 @@ import com.mogo.eagle.core.data.config.FunctionBuildConfig.accThreshold
|
||||
import com.mogo.eagle.core.data.map.MogoLocation
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisLamplightListener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisLocationWGS84Listener
|
||||
import com.mogo.eagle.core.function.api.setting.IMoGoSkinModeChangeListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLamplightListenerManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationWGS84ListenerManager
|
||||
import com.mogo.eagle.core.function.call.setting.CallerSkinModeListenerManager
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_MAP
|
||||
import com.mogo.map.MogoMap
|
||||
@@ -26,7 +24,6 @@ import kotlin.properties.Delegates
|
||||
|
||||
|
||||
class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context, attrs),
|
||||
IMoGoSkinModeChangeListener,
|
||||
IMoGoChassisLocationWGS84Listener, IMoGoChassisLamplightListener, LifecycleObserver {
|
||||
|
||||
companion object {
|
||||
@@ -37,8 +34,7 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
super.onCreate(bundle)
|
||||
map?.uiController?.showMyLocation(true)
|
||||
initMapView()
|
||||
CallerSkinModeListenerManager.addListener(TAG, this)
|
||||
CallerChassisLocationWGS84ListenerManager.addListener(TAG, 20,this)
|
||||
CallerChassisLocationWGS84ListenerManager.addListener(TAG, 20, this)
|
||||
CallerChassisLamplightListenerManager.addListener(TAG, this)
|
||||
|
||||
}
|
||||
@@ -68,15 +64,15 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
return MogoMap.DEFAULT
|
||||
}
|
||||
|
||||
fun getUI(): IMogoMapUIController? {
|
||||
fun getUI(): IMogoMapUIController? {
|
||||
return map?.uiController
|
||||
}
|
||||
|
||||
fun addLine(options:Polyline.Options): IMapPolylineOverlay? {
|
||||
fun addLine(options: Polyline.Options): IMapPolylineOverlay? {
|
||||
return map?.addLine(options)
|
||||
}
|
||||
|
||||
fun addPoint(options: Point.Options): IMapPointOverlay?{
|
||||
fun addPoint(options: Point.Options): IMapPointOverlay? {
|
||||
return map?.addPoint(options)
|
||||
}
|
||||
|
||||
@@ -92,22 +88,14 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
super.onPause()
|
||||
}
|
||||
|
||||
override fun onSkinModeChange(skinMode: Int) {
|
||||
if (skinMode == 0) {
|
||||
getUI()?.stepInDayMode(false)
|
||||
} else if (skinMode == 1) {
|
||||
getUI()?.stepInDayMode(true)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置车辆灯光状态 true 刹车, false 正常
|
||||
*/
|
||||
private var accLimit : Boolean by Delegates.observable(false){ _, oldV, newV ->
|
||||
if(oldV != newV){
|
||||
if(newV){
|
||||
private var accLimit: Boolean by Delegates.observable(false) { _, oldV, newV ->
|
||||
if (oldV != newV) {
|
||||
if (newV) {
|
||||
turn(4)
|
||||
}else{
|
||||
} else {
|
||||
turn(0)
|
||||
}
|
||||
}
|
||||
@@ -119,7 +107,7 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
accLimit = gnssInfo.acceleration < accThreshold
|
||||
}
|
||||
|
||||
private var currentLevel:Int = 0
|
||||
private var currentLevel: Int = 0
|
||||
|
||||
override fun onAutopilotLightSwitchData(lightSwitch: Chassis.LightSwitch?) {
|
||||
super.onAutopilotLightSwitchData(lightSwitch)
|
||||
@@ -128,9 +116,11 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
Chassis.LightSwitch.LIGHT_LEFT_VALUE -> { //左转灯
|
||||
turn(1)
|
||||
}
|
||||
|
||||
Chassis.LightSwitch.LIGHT_RIGHT_VALUE -> { //右转灯
|
||||
turn(2)
|
||||
}
|
||||
|
||||
Chassis.LightSwitch.LIGHT_NONE_VALUE -> {
|
||||
turn(0)
|
||||
}
|
||||
@@ -147,7 +137,6 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
|
||||
override fun onDestroy() {
|
||||
// 先取消注册数据,再onDestroy
|
||||
CallerSkinModeListenerManager.removeListener(TAG)
|
||||
CallerChassisLocationWGS84ListenerManager.removeListener(TAG)
|
||||
CallerChassisLamplightListenerManager.removeListener(TAG)
|
||||
super.onDestroy()
|
||||
|
||||
@@ -7,10 +7,8 @@ import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import androidx.lifecycle.LifecycleObserver
|
||||
import com.mogo.eagle.core.function.api.map.road.IMoGoMapRoadListener
|
||||
import com.mogo.eagle.core.function.api.setting.IMoGoSkinModeChangeListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationWGS84ListenerManager
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapRoadListenerManager
|
||||
import com.mogo.eagle.core.function.call.setting.CallerSkinModeListenerManager
|
||||
import com.mogo.eagle.core.widget.media.video.TextureVideoViewOutlineProvider
|
||||
import com.mogo.map.MogoMap.Companion.MAP_ROAM
|
||||
import com.mogo.map.MogoMapView
|
||||
@@ -19,7 +17,6 @@ import com.mogo.map.uicontroller.VisualAngleMode
|
||||
|
||||
|
||||
class MapRoamView(context: Context?, attrs: AttributeSet?) : MogoMapView(context, attrs),
|
||||
IMoGoSkinModeChangeListener,
|
||||
LifecycleObserver, IMoGoMapRoadListener {
|
||||
|
||||
companion object {
|
||||
@@ -33,7 +30,6 @@ class MapRoamView(context: Context?, attrs: AttributeSet?) : MogoMapView(context
|
||||
override fun onAttachedToWindow() {
|
||||
super.onAttachedToWindow()
|
||||
initMapView()
|
||||
CallerSkinModeListenerManager.addListener(TAG, this)
|
||||
CallerMapRoadListenerManager.addListener(TAG, this)
|
||||
}
|
||||
|
||||
@@ -72,14 +68,6 @@ class MapRoamView(context: Context?, attrs: AttributeSet?) : MogoMapView(context
|
||||
return map?.uiController
|
||||
}
|
||||
|
||||
override fun onSkinModeChange(skinMode: Int) {
|
||||
if (skinMode == 0) {
|
||||
getUI()?.stepInDayMode(false)
|
||||
} else if (skinMode == 1) {
|
||||
getUI()?.stepInDayMode(true)
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressLint("ObsoleteSdkInt")
|
||||
override fun onSizeChanged(w: Int, h: Int, oldw: Int, oldh: Int) {
|
||||
super.onSizeChanged(w, h, oldw, oldh)
|
||||
@@ -111,7 +99,6 @@ class MapRoamView(context: Context?, attrs: AttributeSet?) : MogoMapView(context
|
||||
|
||||
override fun onDestroy() {
|
||||
// 先取消注册数据,再onDestroy
|
||||
CallerSkinModeListenerManager.removeListener(TAG)
|
||||
CallerMapRoadListenerManager.removeListener(TAG)
|
||||
super.onDestroy()
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ import com.mogo.eagle.core.function.map.R
|
||||
import kotlin.random.Random
|
||||
|
||||
|
||||
class RoadCrossRoamListAdapter(private val mContext: Context) : RecyclerView.Adapter<RoadCrossRoamListAdapter.ViewHolder>() {
|
||||
class RoadCrossRoamListAdapter(private val mContext: Context, private val lightMode: Boolean) : RecyclerView.Adapter<RoadCrossRoamListAdapter.ViewHolder>() {
|
||||
|
||||
private val items: MutableList<String> = mutableListOf()
|
||||
|
||||
@@ -35,6 +35,11 @@ class RoadCrossRoamListAdapter(private val mContext: Context) : RecyclerView.Ad
|
||||
|
||||
override fun onBindViewHolder(holder: ViewHolder, position: Int) {
|
||||
val item = items[position]
|
||||
if(lightMode){
|
||||
holder.textView.setTextColor(mContext.getColor(R.color.color_191A1C))
|
||||
}else{
|
||||
holder.textView.setTextColor(mContext.getColor(R.color.white))
|
||||
}
|
||||
holder.textView.text = item
|
||||
// 随机决定是否显示ProgressBar
|
||||
// if (Random.nextBoolean()) { // 50%的几率显示ProgressBar
|
||||
|
||||
@@ -8,6 +8,9 @@ import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.animation.Animation
|
||||
import android.view.animation.AnimationUtils
|
||||
import android.view.animation.LinearInterpolator
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
@@ -21,8 +24,11 @@ import kotlinx.android.synthetic.main.view_road_cross_roam.view.ivCoverRoam
|
||||
import kotlinx.android.synthetic.main.view_road_cross_roam.view.ivRoadRoamClose
|
||||
import kotlinx.android.synthetic.main.view_road_cross_roam.view.lvRoadCrossRoamTip
|
||||
import kotlinx.android.synthetic.main.view_road_cross_roam.view.mapRoamView
|
||||
import kotlinx.android.synthetic.main.view_road_cross_roam_light.view.ivZhiRoadRoamView
|
||||
import kotlinx.android.synthetic.main.view_road_cross_roam_light.view.tvRoadRoamTitle
|
||||
import kotlin.properties.Delegates
|
||||
|
||||
|
||||
class RoadCrossRoamView @JvmOverloads constructor(
|
||||
context: Context,
|
||||
attrs: AttributeSet? = null,
|
||||
@@ -40,12 +46,13 @@ class RoadCrossRoamView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
private var animator: ObjectAnimator? = null
|
||||
private var lightMode = CallerSkinModeListenerManager.getMode() == 1
|
||||
|
||||
init {
|
||||
val res = when (CallerSkinModeListenerManager.getMode()) {
|
||||
0 -> R.layout.view_road_cross_roam
|
||||
1 -> R.layout.view_road_cross_roam_light
|
||||
else -> R.layout.view_road_cross_roam
|
||||
val res = if (lightMode) {
|
||||
R.layout.view_road_cross_roam_light
|
||||
} else {
|
||||
R.layout.view_road_cross_roam
|
||||
}
|
||||
LayoutInflater.from(context).inflate(res, this, true)
|
||||
lvRoadCrossRoamTip.layoutManager = LinearLayoutManager(context)
|
||||
@@ -84,14 +91,15 @@ class RoadCrossRoamView @JvmOverloads constructor(
|
||||
override fun onStopLineInfo(info: StopLine) {
|
||||
super.onStopLineInfo(info)
|
||||
showState = info.distance < 200 && info.distance > 100
|
||||
Log.i("emArrow","showState $showState , distance:${info.distance}")
|
||||
Log.i("emArrow", "showState $showState , distance:${info.distance}")
|
||||
}
|
||||
|
||||
private fun attachView() {
|
||||
this.visibility = View.VISIBLE
|
||||
ivZhiRoadRoamView.visibility = View.VISIBLE
|
||||
mapRoamView.visibility = View.VISIBLE
|
||||
mapRoamView.openRoam()
|
||||
lvRoadCrossRoamTip.adapter = RoadCrossRoamListAdapter(context)
|
||||
lvRoadCrossRoamTip.adapter = RoadCrossRoamListAdapter(context, lightMode)
|
||||
// 创建横向移动的动画
|
||||
if (animator == null) {
|
||||
animator =
|
||||
@@ -106,6 +114,22 @@ class RoadCrossRoamView @JvmOverloads constructor(
|
||||
animator?.repeatCount = ValueAnimator.INFINITE // 设置动画无限重复
|
||||
animator?.repeatMode = ValueAnimator.RESTART // 设置动画来回移动
|
||||
animator?.start()
|
||||
|
||||
if (lightMode) {
|
||||
// val rotateAnimation: Animation = AnimationUtils.loadAnimation(
|
||||
// context, R.anim.anim_road_cross_roam
|
||||
// )
|
||||
// ivZhiRoadRoamView.startAnimation(rotateAnimation)
|
||||
val rotationAnim = ObjectAnimator.ofFloat(ivZhiRoadRoamView, "rotation", 0f, 360f)
|
||||
rotationAnim.repeatCount = ValueAnimator.INFINITE
|
||||
rotationAnim.repeatMode = ValueAnimator.RESTART
|
||||
rotationAnim.duration = 1000
|
||||
rotationAnim.interpolator = LinearInterpolator()
|
||||
rotationAnim.start()
|
||||
tvRoadRoamTitle.setTextColor(context.getColor(R.color.color_131415))
|
||||
} else {
|
||||
tvRoadRoamTitle.setTextColor(context.getColor(R.color.white))
|
||||
}
|
||||
}
|
||||
|
||||
private fun detachView() {
|
||||
@@ -113,12 +137,18 @@ class RoadCrossRoamView @JvmOverloads constructor(
|
||||
mapRoamView.visibility = View.GONE
|
||||
lvRoadCrossRoamTip.adapter = null
|
||||
animator?.cancel()
|
||||
if(lightMode){
|
||||
ivZhiRoadRoamView.clearAnimation()
|
||||
}
|
||||
this.visibility = View.GONE
|
||||
}
|
||||
|
||||
override fun onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow()
|
||||
animator?.cancel()
|
||||
if(lightMode){
|
||||
ivZhiRoadRoamView.clearAnimation()
|
||||
}
|
||||
CallerMapRoadListenerManager.removeListener(TAG)
|
||||
}
|
||||
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<animated-rotate xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:drawable="@drawable/anim_road_roam"
|
||||
android:duration="1000"
|
||||
android:fromDegrees="0"
|
||||
android:interpolator="@android:anim/linear_interpolator"
|
||||
android:pivotX="50%"
|
||||
android:pivotY="50%"
|
||||
android:repeatCount="infinite"
|
||||
android:repeatMode="restart"
|
||||
android:toDegrees="360" />
|
||||
@@ -8,15 +8,14 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivRoadRoamClose"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:src="@drawable/bg_close_nor_light"
|
||||
android:padding="@dimen/dp_30"
|
||||
android:layout_width="@dimen/dp_60"
|
||||
android:layout_height="@dimen/dp_60"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:layout_marginEnd="@dimen/dp_20"
|
||||
android:scaleType="center"
|
||||
android:layout_marginTop="@dimen/dp_12"
|
||||
android:layout_marginEnd="@dimen/dp_16"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:src="@drawable/bg_close_nor_light"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<ImageView
|
||||
@@ -36,12 +35,13 @@
|
||||
android:layout_height="@dimen/dp_84"
|
||||
android:layout_marginStart="@dimen/dp_24"
|
||||
android:layout_marginTop="@dimen/dp_24"
|
||||
android:background="@drawable/anim_road_cross_roam"
|
||||
android:background="@drawable/anim_road_roam"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvRoadRoamTitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_20"
|
||||
@@ -57,15 +57,17 @@
|
||||
android:layout_width="@dimen/dp_540"
|
||||
android:layout_height="@dimen/dp_300"
|
||||
android:layout_marginTop="@dimen/dp_160"
|
||||
app:isWeatherEnable="true"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:styleMode="MAP_STYLE_DAY_VR_TAXI" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="@dimen/dp_540"
|
||||
android:layout_height="@dimen/dp_300"
|
||||
android:layout_marginTop="@dimen/dp_160"
|
||||
android:layout_marginStart="@dimen/dp_26"
|
||||
android:layout_marginTop="@dimen/dp_160"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
@@ -73,9 +75,9 @@
|
||||
android:id="@+id/ivCoverRoam"
|
||||
android:layout_width="@dimen/dp_120"
|
||||
android:layout_height="@dimen/dp_300"
|
||||
android:src="@drawable/icon_cover_road_roam"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:src="@drawable/icon_cover_road_roam"
|
||||
tools:ignore="ContentDescription" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
@@ -83,8 +85,8 @@
|
||||
android:id="@+id/lvRoadCrossRoamTip"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_200"
|
||||
android:layout_marginTop="@dimen/dp_30"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:layout_marginTop="@dimen/dp_30"
|
||||
android:layout_marginRight="@dimen/dp_30"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
|
||||
@@ -6,7 +6,9 @@ interface IMoGoVisualAngleChangeProvider: IProvider {
|
||||
|
||||
fun updateLongSightLevel(level: Boolean)
|
||||
|
||||
fun changeAngle(scene: Scene)
|
||||
fun changeScene(scene: Scene)
|
||||
|
||||
fun getCurrentScene(): Scene
|
||||
|
||||
fun addListener(tag: String, listener: OnMoGoVisualAngleSceneChangeListener)
|
||||
|
||||
|
||||
@@ -22,8 +22,12 @@ object CallerVisualAngleManager {
|
||||
}
|
||||
}
|
||||
|
||||
fun changeAngle(scene: Scene) {
|
||||
provider?.changeAngle(scene)
|
||||
fun changeScene(scene: Scene) {
|
||||
provider?.changeScene(scene)
|
||||
}
|
||||
|
||||
fun getCurrentScene(): Scene {
|
||||
return provider?.getCurrentScene() ?: throw AssertionError()
|
||||
}
|
||||
|
||||
fun updateLongSightLevel(level: Boolean) {
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
<color name="color_1A000000">#1A000000</color>
|
||||
<color name="color_FF2966EC">#FF2966EC</color>
|
||||
<color name="color_1F9BFE">#1F9BFE</color>
|
||||
<color name="color_191A1C">#191A1C</color>
|
||||
<color name="color_131415">#131415</color>
|
||||
<color name="color_256BFF">#256BFF</color>
|
||||
<color name="color_3E7BFE">#3E7BFE</color>
|
||||
<color name="color_323C6F">#323C6F</color>
|
||||
|
||||
@@ -1079,9 +1079,11 @@
|
||||
<dimen name="sp_48">48dp</dimen>
|
||||
<dimen name="sp_52">52dp</dimen>
|
||||
<dimen name="sp_55">55dp</dimen>
|
||||
<dimen name="sp_72">72dp</dimen>
|
||||
<dimen name="sp_76">76dp</dimen>
|
||||
<dimen name="sp_94">94dp</dimen>
|
||||
<dimen name="sp_120">120dp</dimen>
|
||||
<dimen name="sp_150">150dp</dimen>
|
||||
<dimen name="sp_195">195dp</dimen>
|
||||
|
||||
|
||||
|
||||
@@ -21,7 +21,12 @@ enum class Level(val zIndex: Int) {
|
||||
GUIDE_ROUTE_LINE(75000),
|
||||
|
||||
/**
|
||||
* 道路围栏区域绘制
|
||||
* 围栏区域绘制
|
||||
*/
|
||||
MAP_POLYGON(76000)
|
||||
MAP_POLYGON(76000),
|
||||
|
||||
/**
|
||||
* 围栏区域底色
|
||||
*/
|
||||
MAP_POLYGON_SOLID(75500)
|
||||
}
|
||||
@@ -56,6 +56,8 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
|
||||
val isShowArrow: Boolean = builder.isShowArrow
|
||||
|
||||
val isFilledIn: Boolean = builder.isFilledIn
|
||||
|
||||
fun builder(): Builder {
|
||||
return builder
|
||||
}
|
||||
@@ -100,6 +102,8 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
|
||||
internal var isShowArrow: Boolean = false
|
||||
|
||||
internal var isFilledIn: Boolean = false
|
||||
|
||||
fun setId(id: String) = apply {
|
||||
this.id = id
|
||||
}
|
||||
@@ -176,6 +180,10 @@ data class Polyline(val id: String, val owner: String, val level: Level, val opt
|
||||
this.isShowArrow = show
|
||||
}
|
||||
|
||||
fun isFilledIn(filled: Boolean) = apply {
|
||||
this.isFilledIn = filled
|
||||
}
|
||||
|
||||
fun build(): Options {
|
||||
if (TextUtils.isEmpty(id)) {
|
||||
id = UUID.randomUUID().toString()
|
||||
|
||||
@@ -75,12 +75,17 @@ class AMapWrapper(map: MapAutoViewHelper?, mapView: MapAutoView, controller: IMo
|
||||
e(TAG, "polyline参数为空")
|
||||
return null
|
||||
}
|
||||
val delegate =
|
||||
(if (polylineOptions.lineWidth > 0) mAMap!!.drawThickLine(polylineOptions) else mAMap!!.drawLine(
|
||||
polylineOptions
|
||||
))
|
||||
?: return null
|
||||
return AMapPolylineWrapper(options.id, delegate, mMapView)
|
||||
if (options.isFilledIn) {
|
||||
val delegate = mAMap?.drawPolygon(polylineOptions)
|
||||
return AMapPolylineWrapper(options.id, delegate, mMapView)
|
||||
} else {
|
||||
val delegate =
|
||||
(if (polylineOptions.lineWidth > 0) mAMap?.drawThickLine(polylineOptions) else mAMap?.drawLine(
|
||||
polylineOptions
|
||||
))
|
||||
?: return null
|
||||
return AMapPolylineWrapper(options.id, delegate, mMapView)
|
||||
}
|
||||
}
|
||||
|
||||
private val batchMarkerOptions = BatchMarkerOptions()
|
||||
|
||||
@@ -7,7 +7,7 @@ import com.zhidaoauto.map.sdk.open.view.MapAutoView
|
||||
import java.util.concurrent.atomic.*
|
||||
import com.zhidaoauto.map.sdk.open.renders.poyline.Polyline
|
||||
|
||||
class AMapPolylineWrapper(private val id: String, private val delegate: Polyline, private val mMapAutoView: MapAutoView): IMapPolylineOverlay {
|
||||
class AMapPolylineWrapper(private val id: String, private val delegate: Polyline?, private val mMapAutoView: MapAutoView): IMapPolylineOverlay {
|
||||
|
||||
private val isDestroyed by lazy { AtomicBoolean(false) }
|
||||
|
||||
@@ -19,7 +19,7 @@ class AMapPolylineWrapper(private val id: String, private val delegate: Polyline
|
||||
override fun destroy() {
|
||||
if (isDestroyed.compareAndSet(false, true)) {
|
||||
try {
|
||||
delegate.destroy()
|
||||
delegate?.destroy()
|
||||
} finally {
|
||||
onRemoveAction?.invoke(id)
|
||||
}
|
||||
@@ -29,7 +29,7 @@ class AMapPolylineWrapper(private val id: String, private val delegate: Polyline
|
||||
override fun remove() {
|
||||
if (isRemoved.compareAndSet(false, true)) {
|
||||
try {
|
||||
delegate.remove()
|
||||
delegate?.remove()
|
||||
} finally {
|
||||
onRemoveAction?.invoke(id)
|
||||
}
|
||||
@@ -40,7 +40,7 @@ class AMapPolylineWrapper(private val id: String, private val delegate: Polyline
|
||||
if (isDestroyed.get() || isRemoved.get()) {
|
||||
return
|
||||
}
|
||||
delegate.setVisible(visible)
|
||||
delegate?.setVisible(visible)
|
||||
}
|
||||
|
||||
override fun isDestroyed(): Boolean {
|
||||
@@ -48,7 +48,7 @@ class AMapPolylineWrapper(private val id: String, private val delegate: Polyline
|
||||
}
|
||||
|
||||
override fun isVisible(): Boolean {
|
||||
return delegate.isVisible()
|
||||
return delegate?.isVisible() ?: false
|
||||
}
|
||||
|
||||
override fun setToTop() {
|
||||
@@ -66,7 +66,7 @@ class AMapPolylineWrapper(private val id: String, private val delegate: Polyline
|
||||
delegate.also {
|
||||
val option = ObjectUtils.fromMogo(options,mMapAutoView)
|
||||
if (option != null) {
|
||||
it.setOption(option)
|
||||
it?.setOption(option)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user