opt
This commit is contained in:
@@ -26,9 +26,7 @@ import static com.mogo.module.common.constants.DataTypes.TYPE_MARKER_CLOUD_WARN_
|
||||
public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedListener {
|
||||
|
||||
private static final String TAG = "V2XWarnDataDrawer";
|
||||
|
||||
private static volatile V2XWarnDataDrawer sInstance;
|
||||
|
||||
private boolean mChangeCarModeStatus;
|
||||
|
||||
private V2XWarnDataDrawer() {
|
||||
@@ -80,21 +78,18 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
markerShowEntity.setMarkerLocation(location);
|
||||
markerShowEntity.setMarkerType(TYPE_MARKER_CLOUD_WARN_DATA);
|
||||
|
||||
WorkThreadHandler.getInstance().postDelayed(() -> {
|
||||
IMogoMarker marker = drawMarker(markerShowEntity);
|
||||
Log.d("liyz", "renderWarnData marker != null ");
|
||||
marker.addDynamicAnchorPosition(new MogoLatLng(data.getCollisionLat(), data.getCollisionLon()), (float) data.getHeading(), 5000);
|
||||
|
||||
//移动完成以后,3s后消失
|
||||
UiThreadHandler.postDelayed( () -> {
|
||||
marker.remove();
|
||||
}, 8000 );
|
||||
|
||||
}, 0);
|
||||
IMogoMarker marker = drawMarker(markerShowEntity);
|
||||
Log.d("liyz", "renderWarnData marker != null ");
|
||||
marker.addDynamicAnchorPosition(new MogoLatLng(data.getCollisionLat(), data.getCollisionLon()), (float) data.getHeading(), 5000);
|
||||
|
||||
//移动完成以后,3s后消失
|
||||
UiThreadHandler.postDelayed(() -> {
|
||||
marker.remove();
|
||||
}, 8000);
|
||||
|
||||
}
|
||||
|
||||
|
||||
public IMogoMarker drawMarker(MarkerShowEntity markerShowEntity) {
|
||||
MogoMarkerOptions options = new MogoMarkerOptions()
|
||||
.object(markerShowEntity)
|
||||
@@ -104,7 +99,7 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
options.icon3DRes(getModelRes(2)); //TODO
|
||||
|
||||
// options.anchorColor("#FF4040");
|
||||
options.anchorColor("#FF3036"); //红色
|
||||
options.anchorColor("#FB3C3CFF"); //红色#FF3036 蓝色:#256BFF
|
||||
IMogoMarker marker = MogoApisHandler.getInstance().getApis().getMapServiceApi().getMarkerManager(mContext).addMarker(markerShowEntity.getMarkerType(), options);
|
||||
iMarkerView.setMarker(marker);
|
||||
marker.setToTop();
|
||||
|
||||
Reference in New Issue
Block a user