[V2X][Road]优化道路标记颜色逻辑

[V2X][Road]优化道路标记颜色逻辑2
This commit is contained in:
renwj
2022-09-28 17:22:03 +08:00
parent 86ea6c9d3d
commit 1d0f1422d5
17 changed files with 829 additions and 47878 deletions

View File

@@ -6,7 +6,6 @@ import com.alibaba.android.arouter.facade.annotation.Route
import com.mogo.cloud.passport.IMoGoTokenCallback
import com.mogo.cloud.passport.MoGoAiCloudClient
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
import com.mogo.commons.debug.DebugConfig
import com.mogo.eagle.core.data.constants.MogoServicePaths
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_MAP
import com.mogo.eagle.core.data.map.MogoLocation
@@ -46,7 +45,7 @@ class MoGoMapDataCollectProvider : IMoGoMapDataCollectProvider, OnTaskListener,
private var hasInit = false
override fun init(context: Context?) {
CallerMapLocationListenerManager.addListener(functionName, this)
CallerMapLocationListenerManager.addListener(functionName, this, false)
executor.set(context?.let {
GatherApi.also { itx ->
itx.init(it,
@@ -65,7 +64,7 @@ class MoGoMapDataCollectProvider : IMoGoMapDataCollectProvider, OnTaskListener,
}
override fun onDestroy() {
CallerMapLocationListenerManager.removeListener("$M_MAP$TAG")
CallerMapLocationListenerManager.removeListener("$M_MAP$TAG", false)
CallerLogger.d("$M_MAP$TAG", "--------- onDestroy --------")
executor.get()?.setOnTaskListener(null)
listeners.clear()
@@ -148,7 +147,7 @@ class MoGoMapDataCollectProvider : IMoGoMapDataCollectProvider, OnTaskListener,
}
}
override fun onLocationChanged(location: MogoLocation?, from: Int) {
override fun onLocationChanged(location: MogoLocation?, from: Int, isGps: Boolean) {
location ?: return
executor.get()?.updateLocation(
location.longitude,

View File

@@ -130,7 +130,7 @@ public class AMapCustomView
CallerAutopilotPlanningListenerManager.INSTANCE.addListener(TAG, moGoAutopilotPlanningListener);
initAMapView(context);
// 注册定位监听
CallerMapLocationListenerManager.INSTANCE.addListener(TAG, this);
CallerMapLocationListenerManager.INSTANCE.addListener(TAG, this, false);
//设置全览模式
overLayerView.setOnClickListener(v -> {
displayCustomOverView();
@@ -258,7 +258,7 @@ public class AMapCustomView
protected void onDetachedFromWindow() {
super.onDetachedFromWindow();
// 注册定位监听
CallerMapLocationListenerManager.INSTANCE.removeListener(TAG);
CallerMapLocationListenerManager.INSTANCE.removeListener(TAG, false);
CallerAutopilotPlanningListenerManager.INSTANCE.removeListener(TAG);
}
@@ -269,7 +269,7 @@ public class AMapCustomView
@Override
public void onLocationChanged(@org.jetbrains.annotations.Nullable MogoLocation location, int from) {
public void onLocationChanged(@org.jetbrains.annotations.Nullable MogoLocation location, int from, boolean isGps) {
mLocation = location;
MarkerDrawerManager.INSTANCE.setLonLat(new Pair(location.getLongitude(), location.getLatitude()));
drawCarMarker(location);

View File

@@ -99,14 +99,14 @@ public class SmallMapDirectionView
initAMapView();
// 注册定位监听
CallerMapLocationListenerManager.INSTANCE.addListener(TAG, this);
CallerMapLocationListenerManager.INSTANCE.addListener(TAG, this, false);
}
@Override
protected void onDetachedFromWindow() {
super.onDetachedFromWindow();
// 注册定位监听
CallerMapLocationListenerManager.INSTANCE.removeListener(TAG);
CallerMapLocationListenerManager.INSTANCE.removeListener(TAG, false);
}
private void initAMapView() {
@@ -162,7 +162,7 @@ public class SmallMapDirectionView
@Override
public void onLocationChanged(@org.jetbrains.annotations.Nullable MogoLocation location, int from) {
public void onLocationChanged(@org.jetbrains.annotations.Nullable MogoLocation location, int from, boolean isGps) {
if (location == null) {
return;
}