diff --git a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/tools/AutoPilotAndCheckView.kt b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/tools/AutoPilotAndCheckView.kt
index c6c1ce249a..562f8806d9 100644
--- a/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/tools/AutoPilotAndCheckView.kt
+++ b/core/function-impl/mogo-core-function-hmi/src/main/java/com/mogo/eagle/core/function/hmi/ui/tools/AutoPilotAndCheckView.kt
@@ -7,6 +7,7 @@ import android.graphics.Color
import android.graphics.drawable.ColorDrawable
import android.os.Process
import android.util.AttributeSet
+import android.util.Log
import android.view.LayoutInflater
import android.view.View
import android.widget.FrameLayout
@@ -113,51 +114,45 @@ class AutoPilotAndCheckView @JvmOverloads constructor(
// if (maxAcceleration > 0) {
// tvAcceleration.text = "加速度 $maxAcceleration m/s²"
// }
- tvAcceleration.text = "每次调整车速±5km/h"
+ tvAcceleration.text = "每次调整车速±5km/h,点击确定生效"
if (speedLimit > 0) {
tvSpeed.text = speedLimit.toString()
}else{
tvSpeed.text = "0"
}
+
ivSpeedReduce.setOnClickListener {
if(speedLimit>=5){
speedLimit -= 5
- //速度显示
- val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
- when {
- isSuccess -> {
- //速度显示
- tvSpeed.text = speedLimit.toString()
- ToastUtils.showShort("车速设置成功,立即生效")
- }
- else -> {
- ToastUtils.showShort("设置车速失败,请启动域控制器")
- }
- }
+ tvSpeed.text = speedLimit.toString()
}else{
ToastUtils.showShort("车速不能再减了")
}
}
+
ivSpeedAdd.setOnClickListener {
if(speedLimit<=55){
speedLimit += 5
- //速度显示
- val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
- when {
- isSuccess -> {
- //速度显示
- tvSpeed.text = speedLimit.toString()
- ToastUtils.showShort("车速设置成功,立即生效")
- }
- else -> {
- ToastUtils.showShort("设置车速失败,请启动域控制器")
- }
- }
+ tvSpeed.text = speedLimit.toString()
}else{
ToastUtils.showShort("车速不能再加了")
}
}
+ //速度确认
+ tvSureModify.setOnClickListener {
+ val isSuccess = CallerAutoPilotManager.setAutoPilotSpeed(speedLimit)
+ when {
+ isSuccess -> {
+ //速度显示
+ tvSpeed.text = speedLimit.toString()
+ ToastUtils.showShort("车速设置成功,立即生效")
+ }
+ else -> {
+ ToastUtils.showShort("设置车速失败,请启动域控制器")
+ }
+ }
+ }
initOchView()
}
diff --git a/core/function-impl/mogo-core-function-hmi/src/main/res/drawable/taxi_loginout_sure_bg.xml b/core/function-impl/mogo-core-function-hmi/src/main/res/drawable/taxi_loginout_sure_bg.xml
new file mode 100644
index 0000000000..d681263571
--- /dev/null
+++ b/core/function-impl/mogo-core-function-hmi/src/main/res/drawable/taxi_loginout_sure_bg.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_auto_pilot_check.xml b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_auto_pilot_check.xml
index a41f32557b..fcdc0ab192 100644
--- a/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_auto_pilot_check.xml
+++ b/core/function-impl/mogo-core-function-hmi/src/main/res/layout/view_auto_pilot_check.xml
@@ -241,6 +241,7 @@
/>
x`
+ android:layout_marginStart="40px" />
+
+