修复UI,预警红边,红绿灯、限速位置

This commit is contained in:
董宏宇
2021-08-20 13:21:49 +08:00
parent dffccf2f4a
commit ac6b0aa0f4
8 changed files with 19 additions and 12 deletions

5
.idea/misc.xml generated
View File

@@ -15,7 +15,12 @@
<entry key="modules/mogo-module-hmi/src/main/res/layout/fragment_warning.xml" value="1.0" />
<entry key="modules/mogo-module-hmi/src/main/res/layout/notification_v2x_msg_vr.xml" value="0.3453125" />
<entry key="modules/mogo-module-hmi/src/main/res/layout/view_traffic_light_vr.xml" value="1.25" />
<entry key="modules/mogo-module-main/src/main/res/drawable-xhdpi/module_main_warning_bkg_bottom.xml" value="0.359375" />
<entry key="modules/mogo-module-main/src/main/res/drawable-xhdpi/module_main_warning_bkg_left.xml" value="0.359375" />
<entry key="modules/mogo-module-main/src/main/res/drawable-xhdpi/module_main_warning_bkg_right.xml" value="0.359375" />
<entry key="modules/mogo-module-main/src/main/res/drawable-xhdpi/module_main_warning_bkg_top.xml" value="0.33" />
<entry key="modules/mogo-module-main/src/main/res/layout/module_main_activity_main.xml" value="0.3125" />
<entry key="modules/mogo-module-main/src/main/res/layout/module_main_activity_main_no_map.xml" value="0.33645833333333336" />
<entry key="modules/mogo-module-service/src/main/res/drawable/bg_adas_dispatch.xml" value="0.184" />
<entry key="modules/mogo-module-service/src/main/res/drawable/bg_adas_dispatch_affirm.xml" value="0.19166666666666668" />
<entry key="modules/mogo-module-service/src/main/res/drawable/bg_map_marker_blue_info.xml" value="0.184" />

View File

@@ -30,7 +30,7 @@ class ViewTrafficLight @JvmOverloads constructor(
* @param checkLightId 0-都是默认1-红2-黄3-绿
*/
fun showWarningTrafficLight(checkLightId: Int) {
clTrafficLight.visibility = View.VISIBLE
visibility = View.VISIBLE
when (checkLightId) {
0 -> {
ctvRedTrafficLight.isChecked = false
@@ -59,7 +59,7 @@ class ViewTrafficLight @JvmOverloads constructor(
* 关闭红绿灯预警展示,并重制灯态
*/
fun disableWarningTrafficLight() {
clTrafficLight.visibility = View.GONE
visibility = View.GONE
ctvRedTrafficLight.isChecked = false
ctvYellowTrafficLight.isChecked = false
ctvGreenTrafficLight.isChecked = false

View File

@@ -12,8 +12,10 @@
android:layout_height="wrap_content"
android:layout_marginTop="40px"
android:layout_marginRight="40px"
android:visibility="gone"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
app:layout_constraintTop_toTopOf="parent"
tools:visibility="visible" />
<TextView
android:id="@+id/tvLimitingVelocity"
@@ -28,6 +30,7 @@
android:visibility="gone"
app:layout_constraintEnd_toEndOf="@+id/viewTrafficLightVr"
app:layout_constraintTop_toBottomOf="@+id/viewTrafficLightVr"
app:layout_goneMarginEnd="40px"
app:layout_goneMarginTop="40px"
tools:visibility="visible" />

View File

@@ -10,7 +10,6 @@
android:paddingTop="10px"
android:paddingEnd="10px"
android:paddingBottom="10px"
android:visibility="gone"
tools:visibility="visible">
<CheckedTextView

View File

@@ -3,6 +3,6 @@
<gradient
android:angle="90"
android:endColor="#00F03232"
android:startColor="#3FF03232"
android:type="linear"></gradient>
android:startColor="#66FF0808"
android:type="linear"/>
</shape>

View File

@@ -3,6 +3,6 @@
<gradient
android:angle="0"
android:endColor="#00F03232"
android:startColor="#3FF03232"
android:type="linear"></gradient>
android:startColor="#66FF0808"
android:type="linear"/>
</shape>

View File

@@ -3,6 +3,6 @@
<gradient
android:angle="180"
android:endColor="#00F03232"
android:startColor="#3FF03232"
android:type="linear"></gradient>
android:startColor="#66FF0808"
android:type="linear"/>
</shape>

View File

@@ -3,6 +3,6 @@
<gradient
android:angle="270"
android:endColor="#00FF0606"
android:startColor="#3FFF0606"
android:type="linear"></gradient>
android:startColor="#66FF0808"
android:type="linear"/>
</shape>