车前引导线 非自动驾驶状态 不绘制车前引导线

This commit is contained in:
lianglihui
2021-11-25 15:48:27 +08:00
parent bfd14106e0
commit b66c53c1db
2 changed files with 6 additions and 4 deletions

View File

@@ -22,7 +22,7 @@ public class MogoRouteOverlayManager implements IMogoCarLocationChangedListener2
private static volatile MogoRouteOverlayManager sInstance;
private Context mContext;
private String TAG = "MogoRouteOverlayManager";
private int STATUS_AUTOPILOT = STATUS_AUTOPILOT_DISABLE;
private MogoRouteOverlayManager(Context context) {
mContext = context;
}
@@ -98,7 +98,9 @@ public class MogoRouteOverlayManager implements IMogoCarLocationChangedListener2
latLngList.add(new MogoLatLng(routeModel.getLat(), routeModel.getLon()));
}
Log.e(TAG, "routeResult:" + latLngList.size());
RouteOverlayDrawer.getInstance(mContext).putRouteList(latLngList);
if (STATUS_AUTOPILOT == IMogoAdasOCHCallback.STATUS_AUTOPILOT_RUNNING) {
RouteOverlayDrawer.getInstance(mContext).putRouteList(latLngList);
}
}
@Override
@@ -108,7 +110,7 @@ public class MogoRouteOverlayManager implements IMogoCarLocationChangedListener2
@Override
public void onStateChanged(int state, String reason) {
// this.STATUS_AUTOPILOT = state;
this.STATUS_AUTOPILOT = state;
if (state != IMogoAdasOCHCallback.STATUS_AUTOPILOT_RUNNING) {
RouteOverlayDrawer.getInstance(mContext).clearMogoRouteOverlay();
}