From 3ae09925b9955336e6ffda8dcb8d99efde5b2043 Mon Sep 17 00:00:00 2001 From: wangcongtao Date: Wed, 30 Dec 2020 16:08:33 +0800 Subject: [PATCH 1/5] opt --- app/functions/httpdns.gradle | 16 ++++++++-------- .../map/impl/custom/CustomMapApiBuilder.java | 3 ++- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/app/functions/httpdns.gradle b/app/functions/httpdns.gradle index 176938bc92..0da084c406 100644 --- a/app/functions/httpdns.gradle +++ b/app/functions/httpdns.gradle @@ -8,10 +8,10 @@ project.dependencies { d8xxImplementation rootProject.ext.dependencies.httpdnsnoop d80xImplementation rootProject.ext.dependencies.httpdnsnoop em4Implementation rootProject.ext.dependencies.httpdnsnoop - e8xxImplementation rootProject.ext.dependencies.httpdnstencent - f8xxImplementation rootProject.ext.dependencies.httpdnstencent - f80xImplementation rootProject.ext.dependencies.httpdnstencent - f8AmapImplementation rootProject.ext.dependencies.httpdnstencent + e8xxImplementation rootProject.ext.dependencies.httpdnsnoop + f8xxImplementation rootProject.ext.dependencies.httpdnsnoop + f80xImplementation rootProject.ext.dependencies.httpdnsnoop + f8AmapImplementation rootProject.ext.dependencies.httpdnsnoop em3Implementation rootProject.ext.dependencies.httpdnsnoop } else { bydautoImplementation project(':foudations:httpdns-noop') @@ -20,10 +20,10 @@ project.dependencies { d8xxImplementation project(':foudations:httpdns-noop') d80xImplementation project(':foudations:httpdns-noop') em4Implementation project(':foudations:httpdns-noop') - e8xxImplementation project(':foudations:httpdns-tencent') - f8xxImplementation project(':foudations:httpdns-tencent') - f80xImplementation project(':foudations:httpdns-tencent') - f8AmapImplementation project(':foudations:httpdns-tencent') + e8xxImplementation project(':foudations:httpdns-noop') + f8xxImplementation project(':foudations:httpdns-noop') + f80xImplementation project(':foudations:httpdns-noop') + f8AmapImplementation project(':foudations:httpdns-noop') em3Implementation project(':foudations:httpdns-noop') } } \ No newline at end of file diff --git a/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/CustomMapApiBuilder.java b/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/CustomMapApiBuilder.java index 2dd9320480..4656d28323 100644 --- a/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/CustomMapApiBuilder.java +++ b/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/CustomMapApiBuilder.java @@ -3,6 +3,7 @@ package com.mogo.map.impl.custom; import android.content.Context; import com.alibaba.android.arouter.facade.annotation.Route; +import com.mogo.commons.debug.DebugConfig; import com.mogo.map.CoordinatesTransformer; import com.mogo.map.IMogoMapApiBuilder; import com.mogo.map.IMogoMapView; @@ -92,7 +93,7 @@ class CustomMapApiBuilder implements IMogoMapApiBuilder { @Override public IMogoMapView getMapView( Context context ) { NavAutoApi.INSTANCE.init( context, MapParams.Companion.init() - .setDebugMode( true ) + .setDebugMode( DebugConfig.isDebug() ) .setCoordinateType( MapParams.COORDINATETYPE_GCJ02 ) .setPerspectiveMode( MapParams.MAP_PERSPECTIVE_2D ) .setZoom( 16 ) From 63002f1bd668cad2676bfa34532816c08570bd2b Mon Sep 17 00:00:00 2001 From: wangcongtao Date: Wed, 30 Dec 2020 16:08:33 +0800 Subject: [PATCH 2/5] bugfix --- .../java/com/mogo/module/service/MogoServices.java | 12 +++++++----- .../mogo/service/impl/adas/MogoADASController.java | 4 ++++ 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/modules/mogo-module-service/src/main/java/com/mogo/module/service/MogoServices.java b/modules/mogo-module-service/src/main/java/com/mogo/module/service/MogoServices.java index fb0db8e17d..dcb08560b4 100644 --- a/modules/mogo-module-service/src/main/java/com/mogo/module/service/MogoServices.java +++ b/modules/mogo-module-service/src/main/java/com/mogo/module/service/MogoServices.java @@ -932,11 +932,13 @@ public class MogoServices implements IMogoMapListener, @Override public void onMapModeChanged( EnumMapUI ui ) { if ( ui == EnumMapUI.Type_VR ) { - MogoApisHandler.getInstance().getApis().getStatusManagerApi().setVrMode( TAG, true ); - MapCenterPointStrategy.resetByChangeMode(); - MapMarkerManager.getInstance().redrawMarkerByStyleChanged(); - AIAssist.getInstance( mContext ).speakTTSVoice( "你已进入鹰眼模式" ); - mLastStatusIsVr = true; + if ( !mLastStatusIsVr ) { + MogoApisHandler.getInstance().getApis().getStatusManagerApi().setVrMode( TAG, true ); + MapCenterPointStrategy.resetByChangeMode(); + MapMarkerManager.getInstance().redrawMarkerByStyleChanged(); + AIAssist.getInstance( mContext ).speakTTSVoice( "你已进入鹰眼模式" ); + mLastStatusIsVr = true; + } } else { if ( mLastStatusIsVr ) { mLastStatusIsVr = false; diff --git a/services/mogo-service/src/main/java/com/mogo/service/impl/adas/MogoADASController.java b/services/mogo-service/src/main/java/com/mogo/service/impl/adas/MogoADASController.java index f82bf29011..f828ef9ab8 100644 --- a/services/mogo-service/src/main/java/com/mogo/service/impl/adas/MogoADASController.java +++ b/services/mogo-service/src/main/java/com/mogo/service/impl/adas/MogoADASController.java @@ -323,6 +323,10 @@ public class MogoADASController implements IMogoADASController { return; } + if ( MogoApisHandler.getInstance().getApis().getStatusManagerApi().isVrMode() ) { + return; + } + try { AutopilotServiceManage.getInstance().showAdas(); } catch ( Exception e ) { From 80ecc411fb04b0a9d4c979fcfe5676aeaabba3f2 Mon Sep 17 00:00:00 2001 From: tongchenfei Date: Wed, 30 Dec 2020 17:10:09 +0800 Subject: [PATCH 3/5] =?UTF-8?q?http=20dns=20noop=20=E7=9B=B4=E6=8E=A5?= =?UTF-8?q?=E8=BF=94=E5=9B=9E=E4=BC=A0=E5=85=A5=E7=9A=84host?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .idea/gradle.xml | 1 + .../src/main/java/com/mogo/httpdns/noop/HttpDnsNoop.java | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.idea/gradle.xml b/.idea/gradle.xml index 426ff6b360..8efbfa420e 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -85,6 +85,7 @@ diff --git a/foudations/httpdns-noop/src/main/java/com/mogo/httpdns/noop/HttpDnsNoop.java b/foudations/httpdns-noop/src/main/java/com/mogo/httpdns/noop/HttpDnsNoop.java index fdf50007aa..5cd0e7df49 100644 --- a/foudations/httpdns-noop/src/main/java/com/mogo/httpdns/noop/HttpDnsNoop.java +++ b/foudations/httpdns-noop/src/main/java/com/mogo/httpdns/noop/HttpDnsNoop.java @@ -26,13 +26,13 @@ class HttpDnsNoop implements IMogoHttpDns { @Override public String getCachedHttpDnsIps( String host,int type ) { - return null; + return host; } @Override public void getHttpDnsIp( String host,int type, boolean useCache, IHttpDnsCallback callback ) { if ( callback != null ) { - callback.onParsed( null ); + callback.onParsed( host ); } } From eb3fd2eea8cadabf1c48fd792065f8778ea1dc3b Mon Sep 17 00:00:00 2001 From: wangcongtao Date: Wed, 30 Dec 2020 17:59:03 +0800 Subject: [PATCH 4/5] =?UTF-8?q?=E5=B0=86=E8=87=AA=E5=8A=A8=E8=BF=9B?= =?UTF-8?q?=E5=85=A5=E9=B9=B0=E7=9C=BC=E6=A8=A1=E5=BC=8F=E7=9A=84=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E8=BF=9B=E8=A1=8C=E5=BB=B6=E6=97=B6=EF=BC=8C=E9=81=BF?= =?UTF-8?q?=E5=85=8D=E5=92=8C=E5=88=9D=E5=A7=8B=E5=8C=96=E7=9A=84=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=E5=86=B2=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/mogo/map/impl/custom/AMapViewWrapper.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/AMapViewWrapper.java b/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/AMapViewWrapper.java index 61a8b483b0..ca6c432960 100644 --- a/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/AMapViewWrapper.java +++ b/libraries/map-custom/src/main/java/com/mogo/map/impl/custom/AMapViewWrapper.java @@ -698,7 +698,10 @@ public class AMapViewWrapper implements IMogoMapView, NaviClient.getInstance( getContext() ).syncCarLocation( sysLocation ); if ( checkAMapView() ) { - MapStyleController.getInstance().onLocationChanged( location, this ); + // 避免设置之后被其他初始化给重置为其他模式 + UiThreadHandler.postDelayed( () -> { + MapStyleController.getInstance().onLocationChanged( location, this ); + }, 5_000L ); } } From a588c7f22bebc31680aa85a367b05abf0e346460 Mon Sep 17 00:00:00 2001 From: wangcongtao Date: Wed, 30 Dec 2020 18:04:55 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E8=87=AA=E7=A0=94?= =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E7=89=88=E6=9C=AC=E4=B8=BA1.0.0-vr-7.5.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- libraries/map-custom/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/map-custom/build.gradle b/libraries/map-custom/build.gradle index e6d6a83127..b7408bfcc7 100644 --- a/libraries/map-custom/build.gradle +++ b/libraries/map-custom/build.gradle @@ -67,7 +67,7 @@ dependencies { implementation project(':foudations:mogo-commons') } - implementation 'com.zhidaoauto.machine:map:1.0.0-vr-7.5.5' + implementation 'com.zhidaoauto.machine:map:1.0.0-vr-7.5.7' // implementation 'com.zhidaoauto.machine:map:1.0.0-vr-7.4.5-log-1' }