A、将位置信息回调由高精地图回调,调整为直接将工控机数据回调给各个模块

Signed-off-by: donghongyu <donghongyu@zhidaoauto.com>
This commit is contained in:
donghongyu
2022-09-21 19:10:21 +08:00
parent 8c31bb7320
commit c3dff0f748
2 changed files with 136 additions and 130 deletions

View File

@@ -744,15 +744,6 @@ public class AMapViewWrapper implements IMogoMapView,
mainHandler.removeCallbacks(mLocationTask);
mainHandler.post(mLocationTask);
}
Location sysLocation = new Location(location.getProvider());
sysLocation.setAltitude(location.getAltitude());
sysLocation.setLatitude(location.getLat());
sysLocation.setLongitude(location.getLon());
sysLocation.setProvider(location.getProvider());
sysLocation.setAccuracy(location.getAcceleration());
sysLocation.setTime(location.duration);
sysLocation.setBearing((float) location.getHeading());
sysLocation.setSpeed(location.getSpeed());
// 将有效经纬度暂存本地提供给下一次的Http-DNS使用防止首次请求位置获取不到
if (location.getLat() > 0 && location.getLon() > 0) {
@@ -766,9 +757,7 @@ public class AMapViewWrapper implements IMogoMapView,
.putString(SharedPrefsConstants.LOCATION_LONGITUDE, String.valueOf(location.getLon()));
}
if (MogoCarLocationChangedListenerRegister.getInstance().getListener() != null) {
MogoCarLocationChangedListenerRegister.getInstance().getListener().onCarLocationChanged2(sysLocation);
}
if (checkAMapView() && mMapLoaded) {
// 地图初始化完成后每隔5s自动判断当前地图的模式
if (mIsFirstLocated) {