Merge remote-tracking branch 'origin/qa_1.1.8' into qa_1.1.8
@@ -75,15 +75,8 @@ class MainService : Service() {
|
||||
private var mLatitude: Double = 0.0
|
||||
lateinit var serviceApis: IMogoServiceApis
|
||||
|
||||
//发送主动上报结果广播给外部
|
||||
// fun sendCustomResult(result: Boolean) {
|
||||
// var intent = Intent(customResultAction)
|
||||
// intent.putExtra("isSuccess", result)
|
||||
// sendBroadcast(intent)
|
||||
// }
|
||||
|
||||
override fun onStartCommand(intent: Intent?, flags: Int, startId: Int): Int {
|
||||
Log.d(TAG, "onStartCommand -----------> ")
|
||||
//清理多媒体资源和sp策略数据
|
||||
clearStrategyType(this)
|
||||
//初始化埋点
|
||||
@@ -95,7 +88,7 @@ class MainService : Service() {
|
||||
VoiceController.initVoice()
|
||||
serviceApis = ARouter.getInstance().build(MogoServicePaths.PATH_SERVICE_APIS).navigation(this) as IMogoServiceApis
|
||||
speed = serviceApis.getMapServiceApi().getSingletonLocationClient(this).getLastKnowLocation().getSpeed()
|
||||
Log.d(TAG, "onStartCommand speed = $speed" )
|
||||
Log.d(TAG, "onStartCommand speed = $speed")
|
||||
if (intent != null) {
|
||||
params = intent.getParcelableExtra("params")
|
||||
params?.let {
|
||||
@@ -105,18 +98,12 @@ class MainService : Service() {
|
||||
mLongitude = it.lon
|
||||
mLatitude = it.lat
|
||||
Log.d(TAG, "onStartCommand shareType = $shareType --fromType = $fromType --mainInfoId = $mainInfoId -- mLongitude = $mLongitude --mLatitude = $mLatitude --it.duration = ${it.duration} ")
|
||||
// if (shareType == TANLU_ROAD_CONGESTION || shareType == TANLU_TRAFFIC_CHECK || shareType == TANLU_ROAD_CLOSURE || shareType == TANLU_ROAD_CURRENT
|
||||
// || shareType == TANLU_ROAD_PONDING || shareType == TANLU_ROAD_ICING || shareType == TANLU_ROAD_HEAVY_FOG
|
||||
// || shareType == TANLU_ROAD_ACCIDENT || shareType == TANLU_ROAD_WORK
|
||||
// ) {
|
||||
// takePhoto(1, false, true)
|
||||
if (fromType == UPLOAD_FROM_STRATEGY_ACCIDENT_AUTO || fromType == UPLOAD_FROM_STRATEGY_BLOCK_AUTO) {
|
||||
// 如果是策略上报,isCustom = false
|
||||
takeVideo(it.duration)
|
||||
} else {
|
||||
takeVideo(it.duration, isCustom = true, id = id)
|
||||
}
|
||||
// }
|
||||
if (fromType == UPLOAD_FROM_STRATEGY_ACCIDENT_AUTO || fromType == UPLOAD_FROM_STRATEGY_BLOCK_AUTO) {
|
||||
// 如果是策略上报,isCustom = false
|
||||
takeVideo(it.duration)
|
||||
} else {
|
||||
takeVideo(it.duration, isCustom = true, id = id)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
Log.e(TAG, "intent == null ")
|
||||
@@ -210,20 +197,6 @@ class MainService : Service() {
|
||||
// )
|
||||
}
|
||||
|
||||
// private fun sendMarkerInfoReceiver(lat: Double, lon: Double, imageUrl: String?, type: String?) {
|
||||
// Log.e("MainService", "sendMarkerInfoReceiver ------> type = $type ")
|
||||
// Log.e("MainService", "sendMarkerInfoReceiver ------> fromType = $fromType ")
|
||||
// Log.e("MainService", "sendMarkerInfoReceiver ------> isCustom = $isCustom ")
|
||||
// var intent = Intent()
|
||||
// intent.action = "com.zhidao.roadcondition.marker.info"
|
||||
// intent.putExtra("type", type)
|
||||
// intent.putExtra("imageUrl", imageUrl)
|
||||
// intent.putExtra("lat", lat)
|
||||
// intent.putExtra("lon", lon)
|
||||
// intent.putExtra("custom", isCustom)
|
||||
// intent.putExtra("fromType", fromType)
|
||||
// sendBroadcast(intent)
|
||||
// }
|
||||
|
||||
/**
|
||||
* 初始化定位监听
|
||||
@@ -290,7 +263,7 @@ class MainService : Service() {
|
||||
}
|
||||
|
||||
//获取图片
|
||||
private fun takePhoto( isInterval: Boolean = false, isCustom: Boolean = false) {
|
||||
private fun takePhoto(isInterval: Boolean = false, isCustom: Boolean = false) {
|
||||
Log.d("MainService", "takePhoto -----1----->")
|
||||
//判断是否授权
|
||||
// if (isAuthorization(BaseApplication.getAppContext())) {
|
||||
@@ -388,7 +361,7 @@ class MainService : Service() {
|
||||
override fun onDestroy() {
|
||||
super.onDestroy()
|
||||
unregisterReceiver(mAlarmBroadCast)
|
||||
unregisterReceiver(mCustomSendBroadCast)
|
||||
// unregisterReceiver(mCustomSendBroadCast)
|
||||
CarCorderController.release()
|
||||
CosCallbackMapController.release()
|
||||
LatLngStickyEventBus.getInstance().unregister(this)
|
||||
|
||||
|
Before Width: | Height: | Size: 3.2 KiB After Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/module_common_icon_close_press" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/module_common_icon_close" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/module_common_icon_close" />
|
||||
</selector>
|
||||
@@ -129,6 +129,7 @@ class LauncherCardRefresher {
|
||||
switch ( msg.what ) {
|
||||
case MSG_WAIT_NETWORK:
|
||||
trtRequestNetworkConfigStrategy();
|
||||
break;
|
||||
case MSG_LOAD_NET_CONFIG:
|
||||
loadNetworkConfigStrategy();
|
||||
break;
|
||||
@@ -526,9 +527,18 @@ class LauncherCardRefresher {
|
||||
} else if ( datum instanceof TtsConfigData.NearRoads ) {
|
||||
result = handleNearRoadsTtsConfig( ( ( TtsConfigData.NearRoads ) datum ) );
|
||||
} else if ( datum instanceof TtsConfigData.OnlineCarVsExplorerWay ) {
|
||||
result = handleExplorerWayTtsConfig( ( ( TtsConfigData.OnlineCarVsExplorerWay ) datum ) );
|
||||
if ( !result ) {
|
||||
if ( node.type == LauncherCardRefreshType.ExplorerWay ) {
|
||||
result = handleExplorerWayTtsConfig( ( ( TtsConfigData.OnlineCarVsExplorerWay ) datum ) );
|
||||
if ( !result ) {
|
||||
node.type = LauncherCardRefreshType.OnlineCar;
|
||||
result = handleOnlineCarTtsConfig( ( ( TtsConfigData.OnlineCarVsExplorerWay ) datum ) );
|
||||
}
|
||||
} else if( node.type == LauncherCardRefreshType.OnlineCar ){
|
||||
result = handleOnlineCarTtsConfig( ( ( TtsConfigData.OnlineCarVsExplorerWay ) datum ) );
|
||||
if ( !result ) {
|
||||
node.type = LauncherCardRefreshType.ExplorerWay;
|
||||
result = handleExplorerWayTtsConfig( ( ( TtsConfigData.OnlineCarVsExplorerWay ) datum ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
if ( result ) {
|
||||
@@ -594,7 +604,7 @@ class LauncherCardRefresher {
|
||||
String tts = mContext.getString( R.string.module_service_launcher_card_tips );
|
||||
String info = mContext.getString( R.string.module_service_launcher_card_info );
|
||||
speakTTS( String.format( tts, explorerWay.poiTotal, LauncherCardRefreshType.ExplorerWay.getDesc() ), false );
|
||||
notifyRefreshChanged( String.format( info, explorerWay.poiTotal, LauncherCardRefreshType.ExplorerWay ), explorerWay.poiTotal, tts );
|
||||
notifyRefreshChanged( String.format( info, explorerWay.poiTotal, LauncherCardRefreshType.ExplorerWay.getDesc() ), explorerWay.poiTotal, tts );
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -611,7 +621,7 @@ class LauncherCardRefresher {
|
||||
String tts = mContext.getString( R.string.module_service_launcher_card_tips );
|
||||
String info = mContext.getString( R.string.module_service_launcher_card_info );
|
||||
speakTTS( String.format( tts, onlineCar.carTotal, LauncherCardRefreshType.OnlineCar.getDesc() ), false );
|
||||
notifyRefreshChanged( String.format( info, onlineCar.carTotal, LauncherCardRefreshType.OnlineCar ), onlineCar.carTotal, tts );
|
||||
notifyRefreshChanged( String.format( info, onlineCar.carTotal, LauncherCardRefreshType.OnlineCar.getDesc() ), onlineCar.carTotal, tts );
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 434 B |
|
Before Width: | Height: | Size: 434 B |
|
Before Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 434 B |
@@ -28,7 +28,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end"
|
||||
android:layout_marginTop="@dimen/module_services_online_car_panel_close_margin_top"
|
||||
android:src="@drawable/module_services_close" />
|
||||
android:src="@drawable/module_common_close_selector" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/module_services_id_loading"
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/v2x_panel_close_press" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/v2x_panel_close" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/v2x_panel_close" />
|
||||
</selector>
|
||||
@@ -18,5 +18,5 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:src="@drawable/v2x_panel_close" />
|
||||
android:src="@drawable/module_common_close_selector" />
|
||||
</RelativeLayout>
|
||||
@@ -87,7 +87,7 @@
|
||||
android:layout_width="@dimen/dp_79"
|
||||
android:layout_height="@dimen/dp_79"
|
||||
android:layout_marginRight="@dimen/dp_50"
|
||||
android:background="@drawable/v2x_selector_close"
|
||||
android:background="@drawable/module_common_close_selector"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/rgTabSelect"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/rgTabSelect" />
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
android:layout_height="@dimen/dp_88"
|
||||
android:layout_marginEnd="@dimen/dp_32"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:background="@drawable/v2x_selector_close"
|
||||
android:background="@drawable/module_common_close_selector"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:src="@drawable/v2x_panel_close" />
|
||||
android:src="@drawable/module_common_close_selector" />
|
||||
</com.mogo.module.v2x.view.RoundLayout>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 3.3 KiB |
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/service_car_pannel_call_pressed_light" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/service_car_pannel_call_nomal_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/service_car_pannel_call_nomal_light" />
|
||||
</selector>
|
||||
@@ -1,6 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/service_car_pannel_detials_pressed_light" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/service_car_pannel_detials_nomal_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/service_car_pannel_detials_nomal_light" />
|
||||
</selector>
|
||||
|
After Width: | Height: | Size: 4.2 KiB |
|
Before Width: | Height: | Size: 7.5 KiB After Width: | Height: | Size: 7.5 KiB |
|
Before Width: | Height: | Size: 7.2 KiB After Width: | Height: | Size: 7.2 KiB |
|
Before Width: | Height: | Size: 6.8 KiB After Width: | Height: | Size: 6.8 KiB |
|
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 6.4 KiB |
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/service_car_panel_call_pressed_light" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/service_car_panel_call_normal_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/service_car_panel_call_normal_light" />
|
||||
</selector>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/service_car_panel_details_pressed_light" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/service_car_panel_details_normal_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/service_car_panel_details_normal_light" />
|
||||
</selector>
|
||||
|
After Width: | Height: | Size: 3.2 KiB |
|
After Width: | Height: | Size: 3.1 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 2.9 KiB |
|
Before Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 6.0 KiB |
|
After Width: | Height: | Size: 2.5 KiB |
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/v2x_panel_close_press_light" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/v2x_panel_close_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/v2x_panel_close_light" />
|
||||
<item android:drawable="@drawable/module_common_icon_close_press" android:state_pressed="true" />
|
||||
<item android:drawable="@drawable/module_common_icon_close" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/module_common_icon_close" />
|
||||
</selector>
|
||||