Merge remote-tracking branch 'origin/qa_1.1.8' into qa_1.1.8

This commit is contained in:
tongchenfei
2020-11-27 10:44:56 +08:00
37 changed files with 49 additions and 66 deletions

View File

@@ -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)

View File

@@ -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>

View File

@@ -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;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 434 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 434 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 434 B

View File

@@ -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"

View File

@@ -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>

View File

@@ -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>

View File

@@ -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" />

View File

@@ -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" />

View File

@@ -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>

View File

@@ -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>

View File

@@ -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>

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@@ -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>

View File

@@ -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>

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

View File

@@ -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>