[6.3.0][Feat]新增高精地图天气效果开关

This commit is contained in:
chenfufeng
2024-03-14 15:01:52 +08:00
parent f5445a24da
commit 4bb584d530
4 changed files with 31 additions and 0 deletions

View File

@@ -81,6 +81,7 @@ import kotlinx.android.synthetic.main.view_sop_setting.view.scV2XSwitch
import kotlinx.android.synthetic.main.view_sop_setting.view.scV2iPnc
import kotlinx.android.synthetic.main.view_sop_setting.view.scV2nPnc
import kotlinx.android.synthetic.main.view_sop_setting.view.scWeakNetSlowDown
import kotlinx.android.synthetic.main.view_sop_setting.view.scWeatherSwitch
import kotlinx.android.synthetic.main.view_sop_setting.view.sopLayout
import kotlinx.android.synthetic.main.view_sop_setting.view.tvOverTakeLimit
import kotlinx.android.synthetic.main.view_sop_setting.view.tvPullTimeTitle
@@ -737,6 +738,17 @@ internal class SOPSettingView @JvmOverloads constructor(
}
}
scWeatherSwitch?.also {
if (!AppIdentityModeUtils.isDriver(FunctionBuildConfig.appIdentityMode)) {
it.visibility = GONE
} else {
it.visibility = VISIBLE
it.setOnCheckedChangeListener { _, isChecked ->
CallerMapUIServiceManager.getMapUIController()?.setWeatherEnable(isChecked)
}
}
}
// 清扫车业务模式切换
scSweeperModeSwitch?.also { switchView ->
switchView.isChecked =

View File

@@ -757,6 +757,20 @@
app:layout_constraintRight_toRightOf="@id/otherGuideLine"
app:layout_constraintTop_toBottomOf="@id/scNew360LookAround" />
<!--天气效果开关-->
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/scWeatherSwitch"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_25"
android:scaleX="1.2"
android:scaleY="1.2"
android:checked="true"
android:text="天气效果开关"
app:layout_constraintLeft_toLeftOf="@id/scIPCReport"
app:layout_constraintRight_toRightOf="@id/scIPCReport"
app:layout_constraintTop_toBottomOf="@id/scIPCReport" />
<TextView
android:id="@+id/tvPullTimeTitle"
android:layout_width="wrap_content"

View File

@@ -335,4 +335,5 @@ interface IMogoMapUIController {
* 获取高精地图截图
*/
fun getMapScreenShot()
fun setWeatherEnable(enable: Boolean)
}

View File

@@ -945,4 +945,8 @@ class AMapViewWrapper(mMapView: MapAutoView) : IMogoMapView, IMogoMapUIControlle
CallerMapScreenListenerManager.invokeMapScreen(it)
}
}
override fun setWeatherEnable(enable: Boolean) {
mMapView.getMapAutoViewHelper()?.setWeatherEnable(enable)
}
}