This commit is contained in:
wangcongtao
2020-08-14 09:42:24 +08:00
parent 963c965e55
commit 58311d4a6a
3 changed files with 28 additions and 8 deletions

View File

@@ -38,13 +38,18 @@ class CustomNaviInterrupter implements Interrupter {
/**
* 判断是否用自己的导航
* 1. 项目是否强制使用自己的导航
* 2. 是否安装了高德车机版地图
* 3. 默认使用自己的导航
*
* @return true-用高德公版车机版地图 false-用Launcher自己的导航
*/
@Override
public boolean interrupt() {
if ( AppUtils.isAppInstalled( AbsMogoApplication.getApp(), "com.autonavi.amapauto" )
|| !DebugConfig.isUseCustomNavi() ) {
Logger.d( TAG, "do not use custom map function." );
if ( DebugConfig.isUseCustomNavi() ) {
return false;
}
if ( AppUtils.isAppInstalled( AbsMogoApplication.getApp(), "com.autonavi.amapauto" ) ) {
return true;
}
return false;