opt
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 375 KiB |
@@ -156,10 +156,17 @@ def generateVersionCode() {
|
||||
} else {
|
||||
throw new GradleException("版本号必须定义为 x.y.z,x[1,99], y[0, 99], z[0, 99])")
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
repositories {
|
||||
flatDir {
|
||||
dirs 'libs'
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
||||
implementation fileTree(dir: 'libs', include: ['*.jar', '*.aar'])
|
||||
|
||||
//Crash日志收集
|
||||
implementation rootProject.ext.dependencies.crashSdk
|
||||
|
||||
107
app/libs/t.txt
107
app/libs/t.txt
@@ -1,107 +0,0 @@
|
||||
mogoLatLngs.add( new MogoLatLng(39.615986, 116.396716));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616007, 116.396995));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616012, 116.397169));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616017, 116.397343));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616022, 116.397517));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616029, 116.397693));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616039, 116.397896));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616051, 116.3981));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616058, 116.39827));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616066, 116.398441));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616074, 116.398612));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616083, 116.398787));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616093, 116.39899));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616105, 116.399195));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616112, 116.399334));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61612, 116.399473));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616128, 116.399612));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616136, 116.399751));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616148, 116.399893));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616153, 116.40008));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616159, 116.400301));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616167, 116.400471));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616175, 116.400642));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616183, 116.400813));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616192, 116.400988));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616201, 116.401191));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616213, 116.401396));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616235, 116.401728));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616246, 116.401986));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61625, 116.402146));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616255, 116.402307));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61626, 116.402468));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616267, 116.40263));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616272, 116.402762));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616277, 116.402894));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616282, 116.403026));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616287, 116.403158));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616292, 116.40329));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616297, 116.403422));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616302, 116.403554));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616307, 116.403686));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616321, 116.403821));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616331, 116.404045));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616343, 116.404272));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616353, 116.404551));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616363, 116.404753));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616375, 116.404958));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616375, 116.405055));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616379, 116.405184));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616384, 116.405313));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616389, 116.405442));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616394, 116.405571));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616399, 116.4057));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616404, 116.405829));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616409, 116.405958));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616414, 116.406087));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616419, 116.406216));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616424, 116.406345));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616429, 116.406474));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61644, 116.406611));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616461, 116.406879));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616465, 116.407033));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616469, 116.407187));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616473, 116.407341));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616477, 116.407495));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616483, 116.407694));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616493, 116.407876));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616504, 116.408059));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616515, 116.408327));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616526, 116.408596));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616536, 116.408757));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616547, 116.409025));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616556, 116.409227));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616568, 116.409432));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616579, 116.409711));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61659, 116.409914));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616601, 116.410119));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616601, 116.410387));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616601, 116.410602));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616622, 116.410816));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616633, 116.411084));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616643, 116.411395));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616654, 116.411492));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616665, 116.411771));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616674, 116.411974));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616686, 116.412178));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616697, 116.412447));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616697, 116.412586));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616718, 116.412876));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616729, 116.413144));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616738, 116.413347));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61675, 116.413551));
|
||||
mogoLatLngs.add( new MogoLatLng(39.61675, 116.41383));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616761, 116.414002));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616761, 116.414098));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616767, 116.414279));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616774, 116.414461));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616782, 116.414645));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616792, 116.41483));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616802, 116.415016));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616814, 116.415203));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616824, 116.415395));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616836, 116.415589));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616842, 116.415745));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616849, 116.415902));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616857, 116.416061));
|
||||
mogoLatLngs.add( new MogoLatLng(39.616868, 116.416307));
|
||||
@@ -141,4 +141,14 @@ public class DebugConfig {
|
||||
public static void setLauncher( boolean isLauncher ) {
|
||||
DebugConfig.sIsLauncher = isLauncher;
|
||||
}
|
||||
|
||||
private static boolean sRequestOnlineCarData = true;
|
||||
|
||||
public static boolean isRequestOnlineCarData() {
|
||||
return sRequestOnlineCarData;
|
||||
}
|
||||
|
||||
public static void setRequestOnlineCarData( boolean sRequestOnlineCarData ) {
|
||||
DebugConfig.sRequestOnlineCarData = sRequestOnlineCarData;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,6 +125,7 @@ public class AutoNaviReceiver extends BroadcastReceiver {
|
||||
break;
|
||||
case MapStateValue.STOP_NAVI:
|
||||
case MapStateValue.STOP_EMULATOR_NAVI:
|
||||
case MapStateValue.APP_START: // 语音退出导航,感觉是杀掉了高德APP了
|
||||
if ( MapState.getInstance().isNaving() ) {
|
||||
MapState.getInstance().setNaving( false );
|
||||
MogoNaviListenerHandler.getInstance().onStopNavi();
|
||||
|
||||
@@ -23,4 +23,6 @@ public interface MapStateValue {
|
||||
int EXIT_APP = 45;
|
||||
|
||||
int DESTINATION = 39;
|
||||
|
||||
int APP_START = 0;
|
||||
}
|
||||
|
||||
@@ -14,6 +14,7 @@ import androidx.annotation.Nullable;
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.google.android.material.bottomsheet.BottomSheetBehavior;
|
||||
import com.mogo.commons.mvp.MvpActivity;
|
||||
import com.mogo.module.apps.model.AppsModel;
|
||||
import com.mogo.service.MogoServicePaths;
|
||||
import com.mogo.service.fragmentmanager.FragmentStackTransactionListener;
|
||||
import com.mogo.service.fragmentmanager.IMogoFragmentManager;
|
||||
@@ -90,6 +91,12 @@ public class AppsListActivity extends MvpActivity< AppsListView, AppsListPresent
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onRestoreInstanceState( Bundle savedInstanceState ) {
|
||||
super.onRestoreInstanceState( savedInstanceState );
|
||||
AppsModel.getInstance( this ).release();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void closeAppsPanel() {
|
||||
finish();
|
||||
|
||||
@@ -28,7 +28,7 @@ import java.util.concurrent.atomic.AtomicBoolean;
|
||||
public class AppsModel {
|
||||
|
||||
private static volatile AppsModel sInstance;
|
||||
private final Context mContext;
|
||||
private Context mContext;
|
||||
|
||||
private AppFilter mAppFilter;
|
||||
|
||||
@@ -54,6 +54,11 @@ public class AppsModel {
|
||||
private AtomicBoolean mIsLoaded = new AtomicBoolean( false );
|
||||
|
||||
public synchronized void release() {
|
||||
if ( mPagedApps != null ) {
|
||||
mPagedApps.clear();
|
||||
}
|
||||
mContext = null;
|
||||
mAppFilter = null;
|
||||
sInstance = null;
|
||||
}
|
||||
|
||||
|
||||
@@ -263,6 +263,11 @@ public class MogoServices implements IMogoMapListener,
|
||||
|
||||
private Handler mThreadHandler;
|
||||
|
||||
/**
|
||||
* 当前限速
|
||||
*/
|
||||
private int mCurrentLimit = 0;
|
||||
|
||||
public void init( Context context ) {
|
||||
mContext = context;
|
||||
|
||||
@@ -357,6 +362,9 @@ public class MogoServices implements IMogoMapListener,
|
||||
} else if ( msg.what == ServiceConst.MSG_REQUEST_DATA ) {
|
||||
if ( msg.obj instanceof RefreshObject ) {
|
||||
RefreshObject ro = ( ( RefreshObject ) msg.obj );
|
||||
if ( ro.mLonLat == null ) {
|
||||
return;
|
||||
}
|
||||
mRefreshModel.refreshData( ro.mLonLat, ro.mRadius, ro.mAmount, ro.mCallback );
|
||||
MapMarkerManager.getInstance().getOnlineCarDataByAutoRefreshStrategy( ro.mLonLat );
|
||||
|
||||
@@ -749,10 +757,11 @@ public class MogoServices implements IMogoMapListener,
|
||||
|
||||
if ( traffic != null ) {
|
||||
|
||||
if ( traffic.getSpeedLimit() <= 0 ) {
|
||||
if ( mCurrentLimit == traffic.getSpeedLimit() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
mCurrentLimit = traffic.getSpeedLimit();
|
||||
Logger.i( TAG, "speed = %d, desc = %s", traffic.getSpeedLimit(), traffic.getDesc() );
|
||||
// 发送当前限速到 adas
|
||||
Intent intent = new Intent( "com.mogo.launcher.adas" );
|
||||
|
||||
@@ -200,4 +200,7 @@ public class ServiceConst {
|
||||
* 返回桌面
|
||||
*/
|
||||
public static final String COMMAND_BACK = "com.ileja.launcher.back";
|
||||
|
||||
public static final int ONLINE_SEARCH_LIMIT = 20;
|
||||
public static final int ONLINE_SEARCH_RADIUS = 2_000;
|
||||
}
|
||||
|
||||
@@ -286,6 +286,10 @@ public class MockIntentHandler implements IntentHandler {
|
||||
case 16:
|
||||
MarkerServiceHandler.getGpsSimulatorManager().close();
|
||||
break;
|
||||
case 17:
|
||||
DebugConfig.setRequestOnlineCarData( intent.getBooleanExtra( "status", true ) );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -65,8 +65,6 @@ class OnlineCarSearchIntentHandler implements IntentHandler {
|
||||
}
|
||||
boolean isFocus = false;
|
||||
boolean isSameCity = false;
|
||||
int limit = 50;
|
||||
int radius = 5_000;
|
||||
switch ( command ) {
|
||||
case ServiceConst.COMMAND_ZHIDAO_NEARBY_FRIEND:
|
||||
case ServiceConst.COMMAND_ZHIDAO_NEARBY_USER_ONLINE:
|
||||
@@ -79,8 +77,8 @@ class OnlineCarSearchIntentHandler implements IntentHandler {
|
||||
target,
|
||||
isFocus,
|
||||
isSameCity,
|
||||
limit,
|
||||
radius );
|
||||
ServiceConst.ONLINE_SEARCH_LIMIT,
|
||||
ServiceConst.ONLINE_SEARCH_RADIUS );
|
||||
break;
|
||||
case ServiceConst.COMMAND_ZHIDAO_NEARBY_FRIEND_BYLOCATION:
|
||||
handleAreaSearch( intent, context, target );
|
||||
@@ -114,8 +112,8 @@ class OnlineCarSearchIntentHandler implements IntentHandler {
|
||||
target,
|
||||
false,
|
||||
false,
|
||||
50,
|
||||
5_000 );
|
||||
ServiceConst.ONLINE_SEARCH_LIMIT,
|
||||
ServiceConst.ONLINE_SEARCH_RADIUS );
|
||||
} else {
|
||||
String cityCode = MarkerServiceHandler.getMogoLocationClient().getLastKnowLocation().getCityCode();
|
||||
IMogoGeoSearch search = MarkerServiceHandler.getMapService().getGeoSearch( context );
|
||||
@@ -131,8 +129,8 @@ class OnlineCarSearchIntentHandler implements IntentHandler {
|
||||
target,
|
||||
false,
|
||||
false,
|
||||
50,
|
||||
5_000 );
|
||||
ServiceConst.ONLINE_SEARCH_LIMIT,
|
||||
ServiceConst.ONLINE_SEARCH_RADIUS );
|
||||
}
|
||||
} );
|
||||
MogoGeocodeQuery mogoGeocodeQuery = new MogoGeocodeQuery();
|
||||
|
||||
@@ -5,6 +5,7 @@ import android.graphics.Rect;
|
||||
import android.text.TextUtils;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.map.MogoLatLng;
|
||||
import com.mogo.map.marker.IMogoMarker;
|
||||
import com.mogo.map.marker.IMogoMarkerClickListener;
|
||||
@@ -691,7 +692,7 @@ public class MapMarkerManager implements IMogoMarkerClickListener,
|
||||
|
||||
public void getOnlineCarDataByAutoRefreshStrategy( MogoLatLng latlng ) {
|
||||
UiThreadHandler.removeCallbacks( runnable );
|
||||
getOnlineCarDataImpl( latlng, false, false, 50, 2_000, false );
|
||||
getOnlineCarDataImpl( latlng, false, false, ServiceConst.ONLINE_SEARCH_LIMIT, ServiceConst.ONLINE_SEARCH_RADIUS, false );
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -714,7 +715,7 @@ public class MapMarkerManager implements IMogoMarkerClickListener,
|
||||
@Override
|
||||
public void run() {
|
||||
Logger.d( TAG, "内部 - 自动刷新在线车辆" );
|
||||
getOnlineCarDataImpl( mCarLatLng, false, false, 50, 2_000, false );
|
||||
getOnlineCarDataImpl( mCarLatLng, false, false, ServiceConst.ONLINE_SEARCH_LIMIT, ServiceConst.ONLINE_SEARCH_RADIUS, false );
|
||||
}
|
||||
};
|
||||
|
||||
@@ -740,6 +741,12 @@ public class MapMarkerManager implements IMogoMarkerClickListener,
|
||||
int radius,
|
||||
boolean fitBounds ) {
|
||||
|
||||
if( DebugConfig.isDebug() ){
|
||||
if ( !DebugConfig.isRequestOnlineCarData() ) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if ( mCarLatLng == null ) {
|
||||
mCarLatLng = latLng;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user