Merge branch 'dev_robotaxi-d_240912_6.7.0' of gitlab.zhidaoauto.com:SCA/L4HA/AndroidApp/MoGoEagleEye into dev_robotaxi-d_240912_6.7.0
This commit is contained in:
@@ -144,7 +144,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
app:layout_constraintRight_toLeftOf="@+id/ivCameraIcon"
|
||||
app:layout_constraintRight_toLeftOf="@+id/viewTrafficLightVr"
|
||||
app:layout_goneMarginRight="@dimen/dp_160"/>
|
||||
|
||||
<!--红绿灯-->
|
||||
|
||||
@@ -238,6 +238,7 @@ import kotlinx.android.synthetic.main.view_debug_setting.view.tbObuLog
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbObuWarningFusionUnion
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbOpenAcceleration
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbOpenSnBinding
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbParrallelDriveViewShowControl
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbReportMore
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbReportWarning
|
||||
import kotlinx.android.synthetic.main.view_debug_setting.view.tbRouteDynamicEffect
|
||||
@@ -1628,6 +1629,20 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
HmiBuildConfig.isShowBusStationStrategyBorderPoint = isChecked
|
||||
}
|
||||
|
||||
/**
|
||||
* 远程代码按钮 展示控制
|
||||
*/
|
||||
tbParrallelDriveViewShowControl.isChecked = HmiBuildConfig.isShowParallelDriveBtnView
|
||||
tbParrallelDriveViewShowControl.setOnCheckedChangeListener { _, isChecked ->
|
||||
HmiBuildConfig.isShowParallelDriveBtnView = isChecked
|
||||
CallerHmiViewControlListenerManager.invokeUpdateParallelDriveViewShow(isChecked)
|
||||
}
|
||||
tbParrallelDriveViewShowControl.visibility =
|
||||
if (AppIdentityModeUtils.isTaxiDriver(FunctionBuildConfig.appIdentityMode))
|
||||
View.VISIBLE
|
||||
else
|
||||
View.GONE
|
||||
|
||||
btnThresholdDefine.setOnClickListener {
|
||||
try {
|
||||
accelerationThresholdNum = etThreshold.text.toString().toDouble()
|
||||
|
||||
@@ -7,22 +7,27 @@ import android.content.Context
|
||||
import android.graphics.Color
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.animation.LinearInterpolator
|
||||
import android.widget.ImageView
|
||||
import android.widget.TextView
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.commons.storage.SharedPrefsMgr
|
||||
import com.mogo.commons.voice.AIAssist
|
||||
import com.mogo.eagle.core.data.config.HmiBuildConfig
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoParallelDrivingActionsListener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoParallelDrivingStatusListener
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IViewControlListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerParallelDrivingActionsListenerManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerParallelDrivingListenerManager
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiViewControlListenerManager
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.function.hmi.ui.utils.HmiActionLog
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.Logger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_HMI
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
@@ -37,7 +42,7 @@ class ParallelDriveView @JvmOverloads constructor(
|
||||
attrs: AttributeSet? = null,
|
||||
defStyleAttr: Int = 0
|
||||
) : ConstraintLayout(context, attrs, defStyleAttr), IMoGoAutopilotStatusListener,
|
||||
IMoGoParallelDrivingActionsListener, IMoGoParallelDrivingStatusListener {
|
||||
IMoGoParallelDrivingActionsListener, IMoGoParallelDrivingStatusListener, IViewControlListener {
|
||||
companion object {
|
||||
private const val TAG = "ParallelDriveView"
|
||||
private const val APP_REQUESTING = 1
|
||||
@@ -78,6 +83,15 @@ class ParallelDriveView @JvmOverloads constructor(
|
||||
CallerAutoPilotStatusListenerManager.addListener("$M_HMI$TAG", this)
|
||||
CallerParallelDrivingListenerManager.addListener("$M_HMI$TAG", this)
|
||||
CallerParallelDrivingActionsListenerManager.addListener("$M_HMI$TAG", this)
|
||||
CallerHmiViewControlListenerManager.addListener("$M_HMI$TAG", this)
|
||||
|
||||
//V6.7.0 平行驾驶目前暂时没启用,默认先不展示 远程代驾 按钮,同时通过 调试面板中开关控制 显示/隐藏
|
||||
visibility = if (HmiBuildConfig.isShowParallelDriveBtnView) View.VISIBLE else View.GONE
|
||||
}
|
||||
|
||||
override fun updateParallelDriveViewShow(isShow: Boolean) {
|
||||
Logger.d(TAG, "isShow -> $isShow")
|
||||
visibility = if (isShow) View.VISIBLE else View.GONE
|
||||
}
|
||||
|
||||
private fun initView() {
|
||||
@@ -453,6 +467,7 @@ class ParallelDriveView @JvmOverloads constructor(
|
||||
CallerAutoPilotStatusListenerManager.removeListener("$M_HMI$TAG")
|
||||
CallerParallelDrivingListenerManager.removeListener("$M_HMI$TAG")
|
||||
CallerParallelDrivingActionsListenerManager.removeListener("$M_HMI$TAG")
|
||||
CallerHmiViewControlListenerManager.removeListener("$M_HMI$TAG")
|
||||
}
|
||||
|
||||
interface ClickEventListener {
|
||||
|
||||
@@ -1486,6 +1486,18 @@
|
||||
android:textOn="关闭「通过公交站计算范围边界点」"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/tbParrallelDriveViewShowControl"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_columnWeight="1"
|
||||
android:layout_margin="2dp"
|
||||
android:gravity="center"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:textOff="展示「远程代驾」按钮"
|
||||
android:textOn="隐藏「远程代码」按钮"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatEditText
|
||||
android:id="@+id/etThreshold"
|
||||
android:layout_width="wrap_content"
|
||||
|
||||
@@ -80,6 +80,11 @@ public class MogoRouteOverlayManager implements
|
||||
public void onGreenWaveViewDismiss() {
|
||||
hasGreenWave.set(false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateParallelDriveViewShow(boolean isShow) {
|
||||
|
||||
}
|
||||
};
|
||||
private MogoRouteOverlayManager() {
|
||||
}
|
||||
|
||||
@@ -114,6 +114,13 @@ object HmiBuildConfig {
|
||||
@Volatile
|
||||
var isShowBusStationStrategyBorderPoint = false
|
||||
|
||||
/**
|
||||
* 是否展示 远程代驾 按钮 (V6.7.0 默认不展示)
|
||||
*/
|
||||
@JvmField
|
||||
@Volatile
|
||||
var isShowParallelDriveBtnView = false
|
||||
|
||||
/**
|
||||
* 主驾是否有人,默认没人
|
||||
*/
|
||||
|
||||
@@ -67,4 +67,9 @@ interface IViewControlListener {
|
||||
* 绿波通行控件隐藏
|
||||
*/
|
||||
fun onGreenWaveViewDismiss() {}
|
||||
|
||||
/**
|
||||
* 更新 远程代驾 按钮 展示/隐藏
|
||||
*/
|
||||
fun updateParallelDriveViewShow(isShow: Boolean) {}
|
||||
}
|
||||
|
||||
@@ -104,4 +104,10 @@ object CallerHmiViewControlListenerManager : CallerBase<IViewControlListener>()
|
||||
}
|
||||
}
|
||||
|
||||
fun invokeUpdateParallelDriveViewShow(isShow: Boolean) {
|
||||
M_LISTENERS.forEach {
|
||||
val listener = it.value
|
||||
listener.updateParallelDriveViewShow(isShow)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user