[merge] merge robobus-d 3.1.0
@@ -1,7 +1,13 @@
|
||||
# 网约车(Online Car Hailing)
|
||||
1. mogo-och-bus:Bus司机端(Bus)
|
||||
2. mogo-och-bus-passenger:Bus乘客端(BusPassenger)
|
||||
3. mogo-och-taxi:Taxi司机端(Taxi)
|
||||
4. mogo-och-taxi-passenger:Taxi乘客端(TaxiPassenger)
|
||||
5. mogo-och-noop:空实现,用于独立鹰眼打包
|
||||
6. mogo-och-sweeper: 清扫车(Sweeper)
|
||||
1. mogo-och-bus: 公交车模式司机端
|
||||
2. mogo-och-bus-passenger: 公交车模式乘客端
|
||||
3. mogo-och-charter 包车模式司机端
|
||||
4. mogo-och-charter-passenger 包车模式乘客端
|
||||
5. mogo-och-common-module 公用代码
|
||||
6. mogo-och-data 数据
|
||||
7. mogo-och-noop: 空实现,用于独立鹰眼打包
|
||||
8. mogo-och-shuttle 接驳模式司机端
|
||||
9. mogo-och-shuttle-passenger 接驳模式乘客屏
|
||||
10. mogo-och-sweeper: 清扫车
|
||||
11. mogo-och-taxi: 出租车模式司机端
|
||||
12. mogo-och-taxi-passenger: 出租车乘客端
|
||||
@@ -30,6 +30,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig;
|
||||
@@ -77,14 +78,23 @@ public class MogoOCHBusPassenger implements IMogoOCH {
|
||||
}
|
||||
|
||||
private void showFragment() {
|
||||
if (mPassengerFragment == null) {
|
||||
FragmentManager supportFragmentManager = mActivity.getSupportFragmentManager();
|
||||
if(mPassengerFragment == null){
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备add fragment======");
|
||||
mPassengerFragment = new BusPassengerRouteFragment();
|
||||
mActivity.getSupportFragmentManager().beginTransaction().add(mContainerId, mPassengerFragment).commitAllowingStateLoss();
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(BusPassengerRouteFragment.TAG);
|
||||
if (fragmentByTag instanceof BusPassengerRouteFragment){
|
||||
mPassengerFragment = (BusPassengerRouteFragment)fragmentByTag;
|
||||
}else {
|
||||
mPassengerFragment = new BusPassengerRouteFragment();
|
||||
}
|
||||
if (!mPassengerFragment.isAdded()){
|
||||
supportFragmentManager.beginTransaction().add(mContainerId, mPassengerFragment,BusPassengerRouteFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备show fragment");
|
||||
mActivity.getSupportFragmentManager().beginTransaction().show(mPassengerFragment).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().show(mPassengerFragment).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
private void hideFragment(){
|
||||
|
||||
@@ -40,7 +40,7 @@ public class BusPassengerRouteFragment extends
|
||||
BusPassengerBaseFragment<BusPassengerRouteFragment, BaseBusPassengerPresenter>
|
||||
implements IBusPassengerMapViewCallback {
|
||||
|
||||
private final String TAG = "BusPassengerRouteFragment";
|
||||
public static final String TAG = "BusPassengerRouteFragment";
|
||||
|
||||
private final List<BusPassengerStation> mStationsList = new ArrayList<>();
|
||||
|
||||
|
||||
@@ -28,6 +28,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.mogo.och.bus.fragment;
|
||||
|
||||
import static com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.M_BUS;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.TextView;
|
||||
|
||||
@@ -14,7 +14,9 @@ import androidx.constraintlayout.widget.Group;
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.mogo.cloud.passport.MoGoAiCloudClientConfig;
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig;
|
||||
import com.mogo.eagle.core.data.map.CenterLine;
|
||||
import com.mogo.eagle.core.data.temp.EventLogout;
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener;
|
||||
@@ -37,6 +39,8 @@ import com.mogo.och.common.module.biz.constant.OchCommonConst;
|
||||
import com.mogo.och.common.module.biz.provider.LoginService;
|
||||
import com.mogo.och.common.module.utils.BlinkAnimationUtil;
|
||||
import com.mogo.och.common.module.utils.OCHThreadPoolManager;
|
||||
import com.mogo.och.common.module.utils.QRUtilsKt;
|
||||
import com.mogo.och.common.module.wigets.BindQRCodeDialog;
|
||||
import com.mogo.och.common.module.wigets.MarqueeTextView;
|
||||
import com.mogo.och.common.module.wigets.OCHCommitDialog;
|
||||
|
||||
@@ -46,6 +50,8 @@ import org.greenrobot.eventbus.ThreadMode;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
import me.jessyan.autosize.utils.AutoSizeUtils;
|
||||
|
||||
|
||||
/**
|
||||
* 网约车小巴界面
|
||||
@@ -125,6 +131,22 @@ public class BusFragment extends BaseBusTabFragment<BusFragment, BusPresenter>
|
||||
if (eventLogout.getMessgae() == EventLogout.LOGOUT_TYPE){
|
||||
CallerLogger.INSTANCE.d(M_BUS + TAG,"changeOverview Event消息去登出");
|
||||
mPresenter.logout();
|
||||
}else if (eventLogout.getMessgae() == EventLogout.SHOW_QR_TYPE){ //显示二维码
|
||||
CallerLogger.INSTANCE.d(M_BUS + TAG,"changeOverview Event qrcode");
|
||||
String qrUrl = String.format(FunctionBuildConfig.urlJson.getBindDriverQRUrl(),
|
||||
MoGoAiCloudClientConfig.getInstance().getSn());
|
||||
Bitmap bmQr = QRUtilsKt.createQRCodeWithPicture(
|
||||
BitmapFactory.decodeResource(getResources(), R.drawable.icon_qr_center_logo)
|
||||
,qrUrl, AutoSizeUtils.dp2px(getContext(),340f),
|
||||
AutoSizeUtils.dp2px(getContext(),340f),true);
|
||||
if (bmQr != null){
|
||||
BindQRCodeDialog.Builder builder = new BindQRCodeDialog.Builder();
|
||||
builder.title(getString(R.string.bind_driver_qr_title))
|
||||
.cancelStr(getString(R.string.qr_cancel))
|
||||
.qrBm(bmQr).build(getContext()).show();
|
||||
}else {
|
||||
CallerLogger.INSTANCE.d(M_BUS + TAG,"bmQr = null ");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -360,16 +382,16 @@ public class BusFragment extends BaseBusTabFragment<BusFragment, BusPresenter>
|
||||
}else {
|
||||
firstStationItem.setStationNameColor(getResources().getColor(R.color.bus_station_tag_txt_un_color));
|
||||
thirdStationItem.setStationNameColor(getResources().getColor(R.color.bus_line_station_color_selected));
|
||||
if (isArrived){ //到终点
|
||||
firstStationItem.setStationPointBg(0);
|
||||
firstStationItem.setStationArrowBg(0);
|
||||
thirdStationItem.setStationPointBg(1);
|
||||
if (isArrived){ //到终点
|
||||
firstStationItem.setStationPointBg(0);
|
||||
firstStationItem.setStationArrowBg(0);
|
||||
thirdStationItem.setStationPointBg(1);
|
||||
|
||||
}else { //到终点途中
|
||||
firstStationItem.setStationPointBg(0);
|
||||
firstStationItem.setStationArrowBg(1);
|
||||
thirdStationItem.setStationPointBg(1);
|
||||
}
|
||||
}else { //到终点途中
|
||||
firstStationItem.setStationPointBg(0);
|
||||
firstStationItem.setStationArrowBg(1);
|
||||
thirdStationItem.setStationPointBg(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -62,10 +62,16 @@ class SwitchLineAdapter(
|
||||
line.taskList,
|
||||
object : SwitchLineTaskAdapter.TaskItemClickListener {
|
||||
override fun onItemClick(position: Int,isCheck:Boolean) {
|
||||
if(isCheck) {
|
||||
checkLineId = line.lineId
|
||||
checkTaskId = line.taskList[position].id
|
||||
}else{
|
||||
try {
|
||||
if (isCheck) {
|
||||
checkLineId = line.lineId
|
||||
checkTaskId = line.taskList[position].id
|
||||
} else {
|
||||
checkLineId = -1
|
||||
checkTaskId = -1
|
||||
}
|
||||
}catch (e:Exception){
|
||||
e.printStackTrace()
|
||||
checkLineId=-1
|
||||
checkTaskId=-1
|
||||
}
|
||||
|
||||
@@ -30,6 +30,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.mogo.och.bus.passenger
|
||||
import android.content.Context
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.fragment.app.FragmentActivity
|
||||
import androidx.fragment.app.FragmentManager
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager.getMapUIController
|
||||
import com.mogo.eagle.core.function.call.setting.CallerMoGoUiSettingManager.stepInDayMode
|
||||
@@ -51,16 +52,26 @@ class MogoOCHBusPassenger : IMogoOCH {
|
||||
}
|
||||
|
||||
private fun showFragment() {
|
||||
val supportFragmentManager: FragmentManager? = mActivity?.supportFragmentManager
|
||||
|
||||
if (mPassengerFragment == null) {
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备add fragment======")
|
||||
mPassengerFragment = MainFragment()
|
||||
mActivity!!.supportFragmentManager.beginTransaction()
|
||||
.add(mContainerId, mPassengerFragment!!).commitAllowingStateLoss()
|
||||
var fragmentByTag: Fragment? = supportFragmentManager?.findFragmentByTag(MainFragment.TAG)
|
||||
mPassengerFragment = if (fragmentByTag is MainFragment){
|
||||
fragmentByTag
|
||||
}else{
|
||||
MainFragment()
|
||||
}
|
||||
|
||||
if (!mPassengerFragment?.isAdded!!){
|
||||
supportFragmentManager?.beginTransaction()
|
||||
?.add(mContainerId, mPassengerFragment!!, MainFragment.TAG)?.commitAllowingStateLoss()
|
||||
}
|
||||
return
|
||||
}
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备show fragment")
|
||||
mActivity!!.supportFragmentManager.beginTransaction().show(mPassengerFragment!!)
|
||||
.commitAllowingStateLoss()
|
||||
supportFragmentManager?.beginTransaction()?.show(mPassengerFragment!!)
|
||||
?.commitAllowingStateLoss()
|
||||
}
|
||||
|
||||
private fun hideFragment() {
|
||||
|
||||
@@ -232,6 +232,7 @@ object CharterPassengerModel {
|
||||
override fun onAutopilotSNRequest() {}
|
||||
override fun onAutopilotArriveAtStation(arrivalNotification: MessagePad.ArrivalNotification?) {
|
||||
mADASStatusCallback?.onAutopilotArriveEnd()
|
||||
CallerLogger.d(SceneConstant.M_BUS_P + TAG,"底盘给到站信息")
|
||||
arriveDest()
|
||||
}
|
||||
|
||||
@@ -403,6 +404,7 @@ object CharterPassengerModel {
|
||||
)
|
||||
// 小于15m到站
|
||||
if (calculateLineDistance < CharterPassengerConst.ARRIVE_AT_START_STATION_DISTANCE) {
|
||||
CallerLogger.d(SceneConstant.M_BUS_P + TAG,"小于15米到站1")
|
||||
arriveDest()
|
||||
}
|
||||
}
|
||||
@@ -708,6 +710,7 @@ object CharterPassengerModel {
|
||||
+ " thread = " + Thread.currentThread().name
|
||||
)
|
||||
if (lastSumLength < CharterPassengerConst.ARRIVE_AT_START_STATION_DISTANCE) {
|
||||
CallerLogger.d(SceneConstant.M_BUS_P + TAG,"小于15米到站2")
|
||||
arriveDest()
|
||||
}
|
||||
iDistanceTimeCallback?.setDistancecAndTime(lastSumLength.toLong(), lastTime.toLong())
|
||||
@@ -849,18 +852,19 @@ object CharterPassengerModel {
|
||||
@Synchronized
|
||||
fun arriveDest() {
|
||||
orderInfo?.lineId?.let {
|
||||
if(orderInfo!!.arriveStatus==OrderInfoResponse.ARRIVING) {
|
||||
if (broadcastList.get("${it}$endKey")==null||broadcastList.get("${it}$endKey")==false) {
|
||||
orderInfo?.siteId?.let { siteId ->
|
||||
if (orderInfo!!.arriveStatus == OrderInfoResponse.ARRIVING) {
|
||||
if (broadcastList.get("${siteId}$endKey") == null || broadcastList.get("${siteId}$endKey") == false) {
|
||||
BusPassengerServiceManager.arriveDest(
|
||||
mContext, lindId = it, object : OchCommonServiceCallback<BaseData> {
|
||||
override fun onSuccess(data: BaseData?) {
|
||||
if (null != data && 0 == data.code) {
|
||||
VoiceManager.arrivedStation(
|
||||
orderInfo!!.siteName!!,
|
||||
orderInfo!!.siteNameKr!!,
|
||||
orderInfo!!.siteNameKr ?: "",
|
||||
VoiceFocusManager.getVoiceCmdCallBack()
|
||||
)
|
||||
broadcastList["${it}$endKey"] = true
|
||||
broadcastList["${siteId}$endKey"] = true
|
||||
// 到站结束自驾
|
||||
CallerAutoPilotControlManager.cancelAutoPilot()
|
||||
// 结束路距计算
|
||||
@@ -875,16 +879,18 @@ object CharterPassengerModel {
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun cleanbroadcastListInfo(){
|
||||
broadcastList.clear()
|
||||
}
|
||||
|
||||
fun leaveStation() {
|
||||
orderInfo?.siteName?.let {cn->
|
||||
orderInfo?.siteNameKr?.let {kr->
|
||||
VoiceManager.leaveStation(cn,kr, VoiceFocusManager.getVoiceCmdCallBack())
|
||||
}
|
||||
|
||||
VoiceManager.leaveStation(cn,orderInfo?.siteNameKr?:"", VoiceFocusManager.getVoiceCmdCallBack())
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -255,6 +255,6 @@ class MainFragment :
|
||||
}
|
||||
|
||||
companion object {
|
||||
private const val TAG = "BusPassengerRouteFragment"
|
||||
public const val TAG = "BusPassengerRouteFragment"
|
||||
}
|
||||
}
|
||||
@@ -441,6 +441,7 @@ class LineSiteView @JvmOverloads constructor(
|
||||
}
|
||||
go2StartCar()
|
||||
CharterPassengerModel.queryOrder()
|
||||
CharterPassengerModel.cleanbroadcastListInfo()
|
||||
} else {
|
||||
tempCheckLineIsSubmit = true
|
||||
ToastUtils.showShort("司机端拒绝请重新选择")
|
||||
|
||||
@@ -29,6 +29,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -41,12 +41,13 @@ class CharterProvider: ICharterOCH{
|
||||
} else {
|
||||
DriverM1Fragment()
|
||||
}
|
||||
if (!driverM1Fragment!!.isAdded) {
|
||||
if (!driverM1Fragment?.isAdded!!) {
|
||||
mContainerId?.let {
|
||||
supportFragmentManager?.beginTransaction()
|
||||
?.add(it, driverM1Fragment!!, DriverM1Fragment.TAG)?.commitAllowingStateLoss()
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
d(TAG, "准备show fragment")
|
||||
supportFragmentManager?.beginTransaction()?.show(driverM1Fragment!!)?.commitAllowingStateLoss()
|
||||
|
||||
@@ -9,5 +9,6 @@ import com.magic.mogo.och.charter.bean.QueryCurrentOrderResponse
|
||||
interface DriverM1OrderCallback {
|
||||
fun updateOrderUI(orderStatus: QueryCurrentOrderResponse.Result) // 到达站
|
||||
fun updateOverCountDown(minutes: Long) //倒计时ms
|
||||
fun clearCountDown() //清除倒计时
|
||||
fun updateReturnCarStatus(returnSuccess: Boolean)
|
||||
}
|
||||
@@ -198,7 +198,7 @@ class DriverM1Fragment : CharterBaseFragment<DriverM1Fragment?, DriverM1Presente
|
||||
}.start()
|
||||
}
|
||||
|
||||
private fun clearCountDownTimer() {
|
||||
fun clearCountDownTimer() {
|
||||
if (countDownTimer != null){
|
||||
countDownTimer?.cancel()
|
||||
countDownTimer = null
|
||||
|
||||
@@ -517,7 +517,7 @@ class DriverM1Model {
|
||||
DriverM1LooperManager.starCountDownLoop()
|
||||
}else{
|
||||
DriverM1LooperManager.stopCountDownLoop()
|
||||
mOrderCallback?.updateOverCountDown(-CharterConst.LOOP_PERIOD_60S)
|
||||
mOrderCallback?.clearCountDown()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -106,6 +106,10 @@ class DriverM1Presenter(view: DriverM1Fragment?) :
|
||||
mView?.updateCountDown(minutes)
|
||||
}
|
||||
|
||||
override fun clearCountDown() {
|
||||
mView?.clearCountDownTimer()
|
||||
}
|
||||
|
||||
override fun updateReturnCarStatus(returnSuccess: Boolean) {
|
||||
mView?.updateReturnCarStatus(returnSuccess)
|
||||
}
|
||||
|
||||
@@ -326,16 +326,13 @@ abstract class CharterBaseFragment<V : IView?, P : Presenter<V>?>() :
|
||||
}else{
|
||||
ctvAutopilotStatusTv!!.setTextColor(resources.getColor(R.color.bus_autopilot_text_color_normal))
|
||||
ctvAutopilotStatusIv!!.setImageResource(R.drawable.bus_ic_autopilot)
|
||||
ctvAutopilotStatusTv!!.text =
|
||||
resources.getString(R.string.bus_loading_autopilot_runnig_tv)
|
||||
ctvAutopilotStatus!!.isClickable = true
|
||||
if (IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_ENABLE == autopilotStatus) { //1可用
|
||||
// ctvAutopilotStatus!!.isSelected = false
|
||||
ctvAutopilotStatus!!.isClickable = true
|
||||
ctvAutopilotStatus!!.background = getDrawable(R.drawable.bus_autopilot_0_1_status_bg)
|
||||
} else if (IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_RUNNING == autopilotStatus) {
|
||||
ctvAutopilotStatusTv!!.text =
|
||||
resources.getString(R.string.bus_loading_autopilot_runnig_tv)
|
||||
ctvAutopilotStatus!!.isClickable = true
|
||||
ctvAutopilotStatus!!.background = getDrawable(R.drawable.bus_autopilot_2_status_bg)
|
||||
// ctvAutopilotStatus!!.isSelected = true
|
||||
} else if (IMoGoAutopilotStatusListener.STATUS_PARALLEL_DRIVING
|
||||
== autopilotStatus){
|
||||
ctvAutopilotStatusTv!!.text =
|
||||
|
||||
@@ -30,6 +30,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
|
||||
@@ -37,16 +37,13 @@ object OchCommonLoginStatusDefaultModel : OchCommonLoginStatusModel() {
|
||||
}
|
||||
loginCallback?.loginSuccess(data)
|
||||
|
||||
updateLoginLocalStatus(isLogin())
|
||||
data?.data?.driverStatus?.let { updateLoginLocalStatus(it) }
|
||||
|
||||
}
|
||||
|
||||
private fun updateLoginLocalStatus(isLogin: Boolean) {
|
||||
var loginCacheStatus = LoginCacheStatus(if (isLogin){
|
||||
1
|
||||
}else {
|
||||
0
|
||||
},DateTimeUtil.getCurrentTimeStamp())
|
||||
private fun updateLoginLocalStatus(loginStatus: Int = 0) {
|
||||
var loginCacheStatus = LoginCacheStatus(loginStatus,DateTimeUtil.getCurrentTimeStamp())
|
||||
|
||||
CacheDataManager.instance.putCacheData(mContext, BusCacheKey.BUS_LOGIN_STATUS_CACHE,
|
||||
GsonUtils.toJson(loginCacheStatus))
|
||||
}
|
||||
@@ -60,7 +57,7 @@ object OchCommonLoginStatusDefaultModel : OchCommonLoginStatusModel() {
|
||||
}
|
||||
loginCallback?.loginFail(isLogin)
|
||||
|
||||
updateLoginLocalStatus(isLogin)
|
||||
updateLoginLocalStatus(0)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -24,6 +24,10 @@ android {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
kotlinOptions {
|
||||
jvmTarget = '1.8'
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
package com.mogo.och.data.bean;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 单个网约车小巴车站信息
|
||||
*
|
||||
@@ -93,6 +95,28 @@ public class BusStationBean {
|
||||
this.leaving = leaving;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this == o) return true;
|
||||
if (o == null || getClass() != o.getClass()) return false;
|
||||
BusStationBean that = (BusStationBean) o;
|
||||
return siteId == that.siteId
|
||||
&& seq == that.seq
|
||||
&& Double.compare(that.gcjLon, gcjLon) == 0
|
||||
&& Double.compare(that.gcjLat, gcjLat) == 0
|
||||
&& Double.compare(that.lon, lon) == 0
|
||||
&& Double.compare(that.lat, lat) == 0
|
||||
&& drivingStatus == that.drivingStatus
|
||||
&& leaving == that.leaving
|
||||
&& name.equals(that.name)
|
||||
&& nameKr.equals(that.nameKr);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return Objects.hash(siteId, name, nameKr, seq, gcjLon, gcjLat, lon, lat, drivingStatus, leaving);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "BusStationBean{" +
|
||||
@@ -107,4 +131,6 @@ public class BusStationBean {
|
||||
", leaving=" + leaving +
|
||||
'}';
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -32,6 +32,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -30,6 +30,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig;
|
||||
@@ -77,14 +78,24 @@ public class MogoOCHBusPassenger implements IMogoOCH {
|
||||
}
|
||||
|
||||
private void showFragment() {
|
||||
if (mPassengerFragment == null) {
|
||||
FragmentManager supportFragmentManager = mActivity.getSupportFragmentManager();
|
||||
if(mPassengerFragment == null){
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备add fragment======");
|
||||
mPassengerFragment = new BusPassengerRouteFragment();
|
||||
mActivity.getSupportFragmentManager().beginTransaction().add(mContainerId, mPassengerFragment).commitAllowingStateLoss();
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(BusPassengerRouteFragment.TAG);
|
||||
if (fragmentByTag instanceof BusPassengerRouteFragment){
|
||||
mPassengerFragment = (BusPassengerRouteFragment)fragmentByTag;
|
||||
}else {
|
||||
mPassengerFragment = new BusPassengerRouteFragment();
|
||||
}
|
||||
if (!mPassengerFragment.isAdded()){
|
||||
supportFragmentManager.beginTransaction().add(mContainerId, mPassengerFragment
|
||||
,BusPassengerRouteFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备show fragment");
|
||||
mActivity.getSupportFragmentManager().beginTransaction().show(mPassengerFragment).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().show(mPassengerFragment).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
private void hideFragment(){
|
||||
|
||||
@@ -273,7 +273,7 @@ public class BusPassengerModel {
|
||||
clearLocalRouteResult();
|
||||
return;
|
||||
}
|
||||
|
||||
CallerLogger.INSTANCE.d( M_BUS_P + TAG, "queryDriverSiteByCoordinate = update");
|
||||
routesResult = result;
|
||||
|
||||
if (mRouteLineInfoCallback != null){
|
||||
@@ -578,6 +578,7 @@ public class BusPassengerModel {
|
||||
public void dynamicCalculateRouteInfo() {
|
||||
//计算当前位置和下一站的剩余点集合
|
||||
//计算剩余点总里程和时间
|
||||
CallerLogger.INSTANCE.d(M_BUS_P + TAG, "轨迹排查==mTwoStationsRouts.size() = " + mTwoStationsRouts.size());
|
||||
if (mTwoStationsRouts.size() == 0){
|
||||
calculateTwoStationsRoute();
|
||||
}
|
||||
|
||||
@@ -41,7 +41,7 @@ public class BusPassengerRouteFragment extends
|
||||
BusPassengerBaseFragment<BusPassengerRouteFragment, BaseBusPassengerPresenter>
|
||||
implements IBusPassengerMapViewCallback {
|
||||
|
||||
private final String TAG = "BusPassengerRouteFragment";
|
||||
public static final String TAG = "BusPassengerRouteFragment";
|
||||
|
||||
private final List<BusStationBean> mStationsList = new ArrayList<>();
|
||||
|
||||
|
||||
@@ -161,4 +161,13 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@+id/bus_p_route_panel" />
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.msgbox.BusPassengerMsgBoxBubbleView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintRight_toLeftOf="@+id/bus_p_route_panel"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:layout_marginRight="@dimen/dp_40"
|
||||
android:layout_marginTop="@dimen/dp_100"
|
||||
/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
BIN
OCH/mogo-och-shuttle-passenger/src/m2/assets/m2_map_style.data
Normal file → Executable file
BIN
OCH/mogo-och-shuttle-passenger/src/m2/assets/m2_map_style_extra.data
Normal file → Executable file
@@ -3,6 +3,7 @@ package com.mogo.och.bus.passenger
|
||||
import android.content.Context
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.fragment.app.FragmentActivity
|
||||
import androidx.fragment.app.FragmentManager
|
||||
import com.alibaba.android.arouter.facade.annotation.Route
|
||||
import com.mogo.commons.module.status.IMogoStatusChangedListener
|
||||
import com.mogo.commons.module.status.MogoStatusManager
|
||||
@@ -58,14 +59,27 @@ class MogoOCHBusPassenger : IMogoOCH, IMogoStatusChangedListener {
|
||||
}
|
||||
|
||||
private fun showFragment() {
|
||||
val supportFragmentManager: FragmentManager? = mActivity?.supportFragmentManager
|
||||
if (mPM2Fragment == null) {
|
||||
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备add fragment======")
|
||||
mPM2Fragment = PM2BaseFragment()
|
||||
mActivity?.supportFragmentManager?.beginTransaction()
|
||||
?.add(mContainerId, mPM2Fragment!!)?.commitAllowingStateLoss()
|
||||
|
||||
var fragmentByTag: Fragment? = supportFragmentManager?.findFragmentByTag(PM2BaseFragment.TAG)
|
||||
|
||||
mPM2Fragment = if (fragmentByTag is PM2BaseFragment){
|
||||
fragmentByTag
|
||||
}else{
|
||||
PM2BaseFragment()
|
||||
}
|
||||
|
||||
if (!mPM2Fragment?.isAdded!!){
|
||||
supportFragmentManager?.beginTransaction()
|
||||
?.add(mContainerId, mPM2Fragment!!, PM2BaseFragment.TAG)?.commitAllowingStateLoss()
|
||||
}
|
||||
return
|
||||
}
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备show fragment")
|
||||
mActivity?.supportFragmentManager?.beginTransaction()?.show(mPM2Fragment!!)
|
||||
supportFragmentManager?.beginTransaction()?.show(mPM2Fragment!!)
|
||||
?.commitAllowingStateLoss()
|
||||
}
|
||||
|
||||
|
||||
@@ -421,7 +421,7 @@ class PM2DrivingModel private constructor() {
|
||||
updateLocalOrder()
|
||||
return
|
||||
}
|
||||
|
||||
d(SceneConstant.M_BUS_P+TAG, "queryDriverSiteByCoordinate= update")
|
||||
routesResult = result
|
||||
|
||||
mDrivingInfoCallback?.updateLine(result.name, result.runningDur)
|
||||
@@ -445,6 +445,7 @@ class PM2DrivingModel private constructor() {
|
||||
mNextStationIndex = i + 1
|
||||
return
|
||||
} else if (station.drivingStatus == BusPassengerConst.STATION_STATUS_STOPPED && !station.isLeaving) {
|
||||
d(SceneConstant.M_BUS_P+TAG,"och-rotting--arrived ")
|
||||
mPreRouteIndex = 0
|
||||
isGoingToNextStation = false
|
||||
startOrStopCalculateRouteInfo(false)
|
||||
@@ -484,7 +485,7 @@ class PM2DrivingModel private constructor() {
|
||||
fun dynamicCalculateRouteInfo(){
|
||||
//计算当前位置和下一站的剩余点集合
|
||||
//计算剩余点总里程和时间
|
||||
|
||||
d(SceneConstant.M_BUS_P + TAG, "och-rotting==mTwoStationsRouts.size() = " + mTwoStationsRouts.size)
|
||||
//计算当前位置和下一站的剩余点集合
|
||||
//计算剩余点总里程和时间
|
||||
if (mTwoStationsRouts.size == 0) {
|
||||
|
||||
@@ -67,6 +67,6 @@ class PM2BaseFragment :
|
||||
}
|
||||
|
||||
companion object {
|
||||
private val TAG = PM2BaseFragment::class.java.simpleName
|
||||
public val TAG = PM2BaseFragment::class.java.simpleName
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.mogo.och.bus.passenger.ui
|
||||
|
||||
import android.graphics.BitmapFactory
|
||||
import android.graphics.drawable.AnimationDrawable
|
||||
import android.os.Bundle
|
||||
import android.view.View
|
||||
import androidx.core.content.ContextCompat
|
||||
@@ -176,7 +177,7 @@ class PM2DrivingInfoFragment :
|
||||
context?.let { auto_tv.setTextColor(ContextCompat.getColor(it,R.color.m2_p_white_color)) }
|
||||
context?.let { auto_tv.background = ContextCompat.getDrawable(it,R.drawable.auto_button_bg) }
|
||||
}else{
|
||||
context?.let { auto_tv.setTextColor(ContextCompat.getColor(it,R.color.m2_button_auto_tv_color)) }
|
||||
context?.let { auto_tv.setTextColor(ContextCompat.getColor(it,R.color.shuttle_color_7094ad)) }
|
||||
context?.let { auto_tv.background = ContextCompat.getDrawable(it,R.drawable.bg_p_m2_auto) }
|
||||
}
|
||||
}
|
||||
@@ -206,9 +207,13 @@ class PM2DrivingInfoFragment :
|
||||
tv_distance.text = resources.getString(R.string.m2_p_empty_remain_km)
|
||||
tv_left_time.text = resources.getString(R.string.m2_p_empty_remain_minute)
|
||||
tv_next_station_title.text = resources.getString(R.string.m2_p_station_title_arrived_tv)
|
||||
iv_animal_list.visibility = View.VISIBLE
|
||||
val animationDrawable = iv_animal_list.drawable as AnimationDrawable
|
||||
animationDrawable.start()
|
||||
haveLineAndArrivedStation()
|
||||
}else{ //前往目的地中
|
||||
tv_next_station_title.text = resources.getString(R.string.shuttle_p_next_station_title)
|
||||
iv_animal_list.visibility = View.GONE
|
||||
haveLineAndArriveingStation()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,8 +20,8 @@ class AdvanceGSYVideoPlayer: StandardGSYVideoPlayer {
|
||||
|
||||
init {
|
||||
hideWidget()
|
||||
GSYVideoType.setShowType(GSYVideoType.SCREEN_MATCH_FULL)
|
||||
//GSYVideoType.setRenderType(GSYVideoType.GLSURFACE)
|
||||
GSYVideoType.setShowType(GSYVideoType.SCREEN_TYPE_16_9)
|
||||
GSYVideoType.setRenderType(GSYVideoType.GLSURFACE)
|
||||
}
|
||||
|
||||
override fun hideAllWidget() {
|
||||
|
||||
@@ -30,6 +30,7 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
|
||||
private var videoRelativeLayout: RelativeLayout? = null
|
||||
private var cacheImage: ImageView? = null
|
||||
|
||||
private var videoViewPlayer: AdvanceGSYVideoPlayer? = null
|
||||
private var gsyVideoOptionBuilder: GSYVideoOptionBuilder? = null
|
||||
private var mOnCompletionListener: GSYSampleCallBack? = null
|
||||
@@ -39,7 +40,7 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
private var mVideoDirPath: String? = ""
|
||||
|
||||
init {
|
||||
mVideoDirPath = context.filesDir.absolutePath+ File.separator + "video" + File.separator
|
||||
mVideoDirPath = context.filesDir.absolutePath + File.separator + "video" + File.separator
|
||||
// mVideoDirPath = Config.downLoadPath
|
||||
initView()
|
||||
}
|
||||
@@ -57,33 +58,31 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
|
||||
private fun initVideoView() {
|
||||
videoRelativeLayout = RelativeLayout(context)
|
||||
addView(videoRelativeLayout, LayoutParams(-1, -1))
|
||||
val outLayout = LayoutParams(-1, -1)
|
||||
addView(videoRelativeLayout, outLayout)
|
||||
|
||||
if (videoViewPlayer === null) {
|
||||
//视频播放控件
|
||||
videoViewPlayer = AdvanceGSYVideoPlayer(context)
|
||||
}
|
||||
|
||||
var layoutParams = LayoutParams(-1, -1)
|
||||
val layoutParams = LayoutParams(-1, -1)
|
||||
//设置videoview占满父view播放
|
||||
layoutParams.addRule(ALIGN_PARENT_LEFT)
|
||||
layoutParams.addRule(ALIGN_PARENT_RIGHT)
|
||||
layoutParams.addRule(ALIGN_PARENT_TOP)
|
||||
layoutParams.addRule(ALIGN_PARENT_BOTTOM)
|
||||
val dp2px = AutoSizeUtils.dp2px(context, 16f)
|
||||
videoRelativeLayout?.outlineProvider = TextureVideoViewOutlineProvider(dp2px.toFloat())
|
||||
videoRelativeLayout?.clipToOutline = true
|
||||
|
||||
videoRelativeLayout?.addView(videoViewPlayer, layoutParams)
|
||||
}
|
||||
|
||||
fun setVideoPath(path: String,cacheImageUrl: String) {
|
||||
fun setVideoPath(path: String, cacheImageUrl: String) {
|
||||
// https://img.zhidaohulian.com/fileServer/online_car_hailing/1676357834634/5.m4v
|
||||
// https://img.zhidaohulian.com/fileServer/online_car_hailing/1676360274126/10.mp4
|
||||
this.fileNetPath = path
|
||||
this.cacheImageUrl = cacheImageUrl
|
||||
val pathList = path.split("/")
|
||||
if (pathList.isNotEmpty()){
|
||||
if (pathList.isNotEmpty()) {
|
||||
this.downloadVideoName = pathList[pathList.size - 1]
|
||||
}
|
||||
}
|
||||
@@ -92,7 +91,7 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
// BitmapHelper.getVideoThumbnail(path) /*获取第一帧图*
|
||||
// OCHThreadPoolManager.getsInstance().execute {
|
||||
// var bitmap = BitmapHelper.getVideoThumbnail(fileNetPath)
|
||||
Logger.d(ImageAndVideoRotation.TAG, "setVideoPath")
|
||||
Logger.d(ImageAndVideoRotation.TAG, "setVideoPath")
|
||||
// ThreadUtils.runOnUiThread {
|
||||
// Logger.d(ImageAndVideoRotation.TAG, "bitmap加载")
|
||||
cacheImage?.setImageResource(R.drawable.m2_p_video_holder)
|
||||
@@ -113,9 +112,10 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
// }
|
||||
}
|
||||
|
||||
fun clearLocalErrorVideo(){
|
||||
fun clearLocalErrorVideo() {
|
||||
if (downloadVideoName.isNotEmpty()
|
||||
&& FileUtils.isFileExists(mVideoDirPath + downloadVideoName)){
|
||||
&& FileUtils.isFileExists(mVideoDirPath + downloadVideoName)
|
||||
) {
|
||||
FileUtils.delete(mVideoDirPath + downloadVideoName)
|
||||
}
|
||||
}
|
||||
@@ -141,28 +141,30 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
Logger.d(ImageAndVideoRotation.TAG, "setVideo")
|
||||
mOnCompletionListener = onCompletionListener
|
||||
//判断是否已经下载
|
||||
if (downloadVideoName.isNotEmpty()){
|
||||
Logger.d(ImageAndVideoRotation.TAG,
|
||||
if (downloadVideoName.isNotEmpty()) {
|
||||
Logger.d(
|
||||
ImageAndVideoRotation.TAG,
|
||||
"video local url = $mVideoDirPath$downloadVideoName"
|
||||
)
|
||||
if (FileUtils.isFileExists(mVideoDirPath+downloadVideoName)){
|
||||
if (FileUtils.isFileExists(mVideoDirPath + downloadVideoName)) {
|
||||
Logger.d(ImageAndVideoRotation.TAG, "have cache startPlay")
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath+downloadVideoName)).toString())
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath + downloadVideoName)).toString())
|
||||
return
|
||||
}
|
||||
startDownLoadVideo()
|
||||
}
|
||||
}
|
||||
|
||||
private fun startDownLoadVideo(){
|
||||
private fun startDownLoadVideo() {
|
||||
//下载视频, 下载成功后再播放
|
||||
Logger.d(ImageAndVideoRotation.TAG, "startDownLoadVideo")
|
||||
FileUtils.createFileDir(mVideoDirPath)
|
||||
DownloadUtils.downLoad(context,fileNetPath,mVideoDirPath
|
||||
,downloadVideoName,5,downListener)
|
||||
DownloadUtils.downLoad(
|
||||
context, fileNetPath, mVideoDirPath, downloadVideoName, 5, downListener
|
||||
)
|
||||
}
|
||||
|
||||
fun startPlay(localVideoPath: String?){
|
||||
fun startPlay(localVideoPath: String?) {
|
||||
if (localVideoPath === "") return
|
||||
try {
|
||||
Logger.d(ImageAndVideoRotation.TAG, "startPlay")
|
||||
@@ -178,12 +180,12 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
videoViewPlayer?.isFocusableInTouchMode = false
|
||||
videoViewPlayer?.setVideoAllCallBack(mOnCompletionListener)
|
||||
videoViewPlayer?.startPlayLogic()
|
||||
}catch (e: Exception){
|
||||
} catch (e: Exception) {
|
||||
Logger.d(ImageAndVideoRotation.TAG, "startPlay e = ${e.message}")
|
||||
}
|
||||
}
|
||||
|
||||
fun onVideoReset(){
|
||||
fun onVideoReset() {
|
||||
videoViewPlayer?.onVideoReset()
|
||||
mOnCompletionListener = null
|
||||
}
|
||||
@@ -200,7 +202,7 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
|
||||
private val downListener = object : IDownload{
|
||||
private val downListener = object : IDownload {
|
||||
override fun onStart(url: String?) {
|
||||
setCacheImageViewVisible()
|
||||
Logger.d(ImageAndVideoRotation.TAG, "download-onStart")
|
||||
@@ -220,21 +222,23 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
|
||||
override fun onFinished(url: String?, threadBean: ThreadBean?) {
|
||||
Logger.d(ImageAndVideoRotation.TAG, "download-onFinished = $url")
|
||||
if (url.equals(fileNetPath)){ //发现下载工具在断网又连网后,已完成的任务又都下载,跳转播放出现问题
|
||||
if (url.equals(fileNetPath)) { //发现下载工具在断网又连网后,已完成的任务又都下载,跳转播放出现问题
|
||||
//下载完成
|
||||
ThreadUtils.runOnUiThread {
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath+downloadVideoName)).toString())
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath + downloadVideoName)).toString())
|
||||
}
|
||||
}else{//如果当前文件不存在再次去下载当前的
|
||||
Logger.d(ImageAndVideoRotation.TAG, "download-onFinished = not current" +
|
||||
",currentUrl = $fileNetPath ")
|
||||
if (FileUtils.isFileExists(mVideoDirPath+downloadVideoName)){
|
||||
} else {//如果当前文件不存在再次去下载当前的
|
||||
Logger.d(
|
||||
ImageAndVideoRotation.TAG, "download-onFinished = not current" +
|
||||
",currentUrl = $fileNetPath "
|
||||
)
|
||||
if (FileUtils.isFileExists(mVideoDirPath + downloadVideoName)) {
|
||||
Logger.d(ImageAndVideoRotation.TAG, "have download startPlay")
|
||||
ThreadUtils.runOnUiThread {
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath+downloadVideoName)).toString())
|
||||
startPlay(Uri.fromFile(File(mVideoDirPath + downloadVideoName)).toString())
|
||||
}
|
||||
return
|
||||
}else{
|
||||
} else {
|
||||
startDownLoadVideo()
|
||||
}
|
||||
}
|
||||
@@ -244,7 +248,7 @@ class AdvanceVideoView @JvmOverloads constructor(
|
||||
Logger.d(ImageAndVideoRotation.TAG, "download-onError-$errorMsg")
|
||||
//出错再次下载
|
||||
if (errorMsg != null) {
|
||||
if (errorMsg.startsWith("initFailed")){
|
||||
if (errorMsg.startsWith("initFailed")) {
|
||||
startDownLoadVideo()
|
||||
}
|
||||
}
|
||||
|
||||
|
After Width: | Height: | Size: 6.9 KiB |
|
After Width: | Height: | Size: 204 KiB |
|
After Width: | Height: | Size: 841 B |
|
After Width: | Height: | Size: 899 B |
|
After Width: | Height: | Size: 172 B |
|
After Width: | Height: | Size: 377 B |
|
After Width: | Height: | Size: 599 B |
|
Before Width: | Height: | Size: 48 KiB After Width: | Height: | Size: 55 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 276 KiB After Width: | Height: | Size: 284 KiB |
|
Before Width: | Height: | Size: 3.7 KiB After Width: | Height: | Size: 2.9 KiB |
|
After Width: | Height: | Size: 924 B |
|
After Width: | Height: | Size: 920 B |
|
After Width: | Height: | Size: 925 B |
|
After Width: | Height: | Size: 894 B |
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 47 KiB |
|
Before Width: | Height: | Size: 38 KiB After Width: | Height: | Size: 50 KiB |
@@ -2,5 +2,5 @@
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_24" />
|
||||
<solid android:color="@color/shuttle_color_b9e7c0"/>
|
||||
<solid android:color="@color/shuttle_color_aeedb8"/>
|
||||
</shape>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<animation-list xmlns:android="http://schemas.android.com/apk/res/android" android:visible="true"
|
||||
android:oneshot="false">
|
||||
<item android:drawable="@drawable/m2_arrived_an_0" android:duration="300"/>
|
||||
<item android:drawable="@drawable/m2_arrived_an_1" android:duration="300"/>
|
||||
<item android:drawable="@drawable/m2_arrived_an_2" android:duration="300"/>
|
||||
|
||||
|
||||
</animation-list>
|
||||
@@ -19,22 +19,33 @@
|
||||
app:mapStylePath="@string/m2_over_map_style_path"
|
||||
app:resetDrawableMarginBottom="@dimen/dp_54"
|
||||
app:resetDrawableMarginRight="@dimen/dp_34"
|
||||
app:compassDrawable="@drawable/amap_custom_corner_m2"
|
||||
app:arrivedDrawable="@drawable/m2_amap_arrived_road"
|
||||
app:unArrivedDrawable="@drawable/m2_amap_arriving_road"
|
||||
app:mapTilt="0"
|
||||
app:leftPadding="200"
|
||||
app:startPointDrawable="@drawable/m2_map_start_icon" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
<ImageView
|
||||
android:id="@+id/cl_left_container_back"
|
||||
android:layout_width="0dp"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_height="match_parent"
|
||||
android:src="@drawable/bg_driving_info_image"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintWidth_percent="0.516"/>
|
||||
|
||||
<View
|
||||
android:id="@+id/cl_left_container"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_driving_info"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintWidth_percent="0.5">
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
app:layout_constraintWidth_percent="0.5"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_line_name_container"
|
||||
android:layout_width="@dimen/dp_661"
|
||||
android:layout_height="@dimen/dp_95"
|
||||
android:layout_height="@dimen/dp_92"
|
||||
android:src="@drawable/shuttle_p_line_name"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
@@ -56,7 +67,7 @@
|
||||
android:id="@+id/line_name_tv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_24"
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:ellipsize="marquee"
|
||||
android:marqueeRepeatLimit="marquee_forever"
|
||||
android:maxWidth="@dimen/dp_600"
|
||||
@@ -121,6 +132,17 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
app:layout_constraintTop_toTopOf="@+id/tv_next_station_title"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/tv_next_station_title"
|
||||
app:layout_constraintStart_toEndOf="@+id/tv_next_station_title"
|
||||
android:id="@+id/iv_animal_list"
|
||||
android:layout_width="@dimen/dp_25"
|
||||
android:layout_height="@dimen/dp_30"
|
||||
android:src="@drawable/bg_p_m2_arrived_station"
|
||||
android:visibility="gone"
|
||||
android:layout_marginStart="@dimen/dp_7" />
|
||||
|
||||
<com.mogo.och.common.module.wigets.MarqueeTextView
|
||||
android:id="@+id/station_name_tv"
|
||||
android:layout_width="0dp"
|
||||
@@ -201,7 +223,8 @@
|
||||
android:background="@drawable/bg_driving_arrived_notice"
|
||||
android:gravity="center"
|
||||
android:text="@string/m2_p_arrived_station_title"
|
||||
android:textColor="@color/shuttle_color_1f860d"
|
||||
android:textColor="@color/shuttle_color_34A61F"
|
||||
android:textStyle="bold"
|
||||
android:layout_marginTop="@dimen/dp_22"
|
||||
android:textSize="@dimen/dp_18"
|
||||
android:visibility="gone"
|
||||
@@ -215,6 +238,7 @@
|
||||
android:id="@+id/aciv_speed_time_bg"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="@dimen/dp_181"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/shuttle_p_card_split"
|
||||
app:layout_constraintEnd_toEndOf="@+id/cl_left_container"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
@@ -227,13 +251,13 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/dp_50"
|
||||
android:layout_marginTop="@dimen/dp_27"
|
||||
android:text="0"
|
||||
android:textColor="@color/m2_p_speed_tv_color"
|
||||
android:textSize="@dimen/dp_60"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintStart_toStartOf="@+id/aciv_speed_time_bg"
|
||||
app:layout_constraintTop_toTopOf="@+id/aciv_speed_time_bg" />
|
||||
app:layout_constraintTop_toTopOf="@+id/viewTextClockHouerMin"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/viewTextClockHouerMin"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_speed_unit"
|
||||
@@ -255,22 +279,22 @@
|
||||
android:background="@drawable/bg_p_m2_auto"
|
||||
android:gravity="center"
|
||||
android:text="@string/m2_p_auto_tv"
|
||||
android:textColor="@color/m2_button_auto_tv_color"
|
||||
android:textColor="@color/shuttle_color_7094ad"
|
||||
android:layout_marginBottom="@dimen/dp_34"
|
||||
android:textSize="@dimen/dp_18"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/speed_tv"
|
||||
app:layout_constraintBottom_toBottomOf="parent" />
|
||||
|
||||
<!-- 转向灯 IMoGoChassisLamplightListener-->
|
||||
<com.mogo.och.bus.passenger.ui.widget.M2TurnLightView
|
||||
android:id="@+id/turn_light_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_12"
|
||||
app:day_light_mode="true"
|
||||
app:layout_constraintLeft_toRightOf="@+id/auto_tv"
|
||||
app:layout_constraintTop_toTopOf="@+id/auto_tv"
|
||||
app:visible="true" />
|
||||
<!-- <com.mogo.och.bus.passenger.ui.widget.M2TurnLightView-->
|
||||
<!-- android:id="@+id/turn_light_view"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- android:layout_marginLeft="@dimen/dp_12"-->
|
||||
<!-- app:day_light_mode="true"-->
|
||||
<!-- app:layout_constraintLeft_toRightOf="@+id/auto_tv"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="@+id/auto_tv"-->
|
||||
<!-- app:visible="false" />-->
|
||||
|
||||
<!-- 红绿灯-->
|
||||
<!-- <com.mogo.och.bus.passenger.ui.widget.M2PTrafficLightView-->
|
||||
@@ -330,9 +354,8 @@
|
||||
android:gravity="center"
|
||||
app:layout_constraintBottom_toTopOf="@+id/viewTextClockWeek"
|
||||
app:layout_constraintStart_toEndOf="@+id/view_split"
|
||||
android:layout_marginEnd="@dimen/dp_90"
|
||||
android:textColor="@color/shuttle_color_17417B"
|
||||
android:layout_marginBottom="@dimen/dp_10"
|
||||
android:layout_marginBottom="@dimen/dp_5"
|
||||
android:includeFontPadding="false"
|
||||
android:textSize="@dimen/dp_18" />
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_width="1080dp"
|
||||
android:layout_height="@dimen/dp_563"/>
|
||||
android:layout_height="@dimen/dp_630"/>
|
||||
|
||||
|
||||
|
||||
@@ -41,10 +41,10 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:layout_marginTop="@dimen/dp_61"
|
||||
android:layout_marginStart="@dimen/dp_20"
|
||||
android:layout_marginEnd="@dimen/dp_20"
|
||||
android:layout_marginStart="@dimen/dp_25"
|
||||
android:layout_marginEnd="@dimen/dp_25"
|
||||
app:blurRadius="@dimen/dp_15"
|
||||
app:shadowColor="#80000000"
|
||||
app:shadowColor="#802F3E67"
|
||||
app:shadowRadius="@dimen/dp_16"
|
||||
app:shadow_position="outer"
|
||||
app:xOffset="0dp"
|
||||
@@ -54,11 +54,11 @@
|
||||
<FrameLayout
|
||||
android:id="@+id/driving_fragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_marginStart="@dimen/dp_35"
|
||||
android:layout_marginEnd="@dimen/dp_35"
|
||||
android:layout_height="@dimen/dp_490"
|
||||
android:layout_marginStart="@dimen/dp_40"
|
||||
android:layout_marginEnd="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_492"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
app:layout_constraintTop_toTopOf="@+id/och_shadow_layout"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/och_shadow_layout"
|
||||
app:layout_constraintEnd_toEndOf="@+id/och_shadow_layout"
|
||||
app:layout_constraintStart_toStartOf="@+id/och_shadow_layout"/>
|
||||
|
||||
@@ -86,13 +86,53 @@
|
||||
<!-- 图片或视频广告-->
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/video_fragment"
|
||||
android:id="@+id/video_fragment_bottom"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_560"
|
||||
android:layout_marginBottom="@dimen/dp_44"
|
||||
android:layout_marginEnd="@dimen/dp_42"
|
||||
android:layout_marginStart="@dimen/dp_42"
|
||||
android:layout_height="572.5dp"
|
||||
android:layout_marginBottom="@dimen/dp_35"
|
||||
android:layout_marginEnd="@dimen/dp_35"
|
||||
android:layout_marginStart="@dimen/dp_35"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"/>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/video_fragment"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="562.5dp"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
android:layout_marginEnd="@dimen/dp_40"
|
||||
android:layout_marginStart="@dimen/dp_40"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"/>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/m2_video_top_left"
|
||||
app:layout_constraintTop_toTopOf="@+id/video_fragment_bottom"
|
||||
app:layout_constraintStart_toStartOf="@+id/video_fragment_bottom"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"/>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/m2_video_top_right"
|
||||
app:layout_constraintTop_toTopOf="@+id/video_fragment_bottom"
|
||||
app:layout_constraintEnd_toEndOf="@+id/video_fragment_bottom"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"/>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/m2_video_bottom_left"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/video_fragment_bottom"
|
||||
app:layout_constraintStart_toStartOf="@+id/video_fragment_bottom"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"/>
|
||||
|
||||
<ImageView
|
||||
android:src="@drawable/m2_video_bottom_right"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/video_fragment_bottom"
|
||||
app:layout_constraintEnd_toEndOf="@+id/video_fragment_bottom"
|
||||
android:layout_width="@dimen/dp_30"
|
||||
android:layout_height="@dimen/dp_30"/>
|
||||
|
||||
<!-- 16 9 -->
|
||||
<!-- 1000 562.5 -->
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -16,7 +16,7 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginStart="@dimen/dp_50" />
|
||||
android:layout_marginStart="@dimen/dp_40" />
|
||||
|
||||
<!--魔方连接状态 蓝牙-->
|
||||
<com.mogo.och.bus.passenger.ui.widget.M2BlueToothView
|
||||
@@ -53,7 +53,7 @@
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:textSize="@dimen/dp_18"
|
||||
android:textColor="@color/m2_power_tv_color"
|
||||
android:layout_marginRight="@dimen/dp_50"
|
||||
android:layout_marginRight="@dimen/dp_40"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
@@ -64,8 +64,8 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
android:src="@drawable/m2_status_bar_logo"
|
||||
android:scaleType="fitXY"
|
||||
android:layout_width="@dimen/dp_96"
|
||||
android:layout_height="@dimen/dp_28"/>
|
||||
android:layout_width="@dimen/dp_94"
|
||||
android:layout_height="@dimen/dp_25"/>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -31,8 +31,9 @@
|
||||
<color name="shuttle_color_6617417B">#6617417B</color>
|
||||
<color name="shuttle_color_17417B">#17417B</color>
|
||||
<color name="shuttle_color_2d3e5f">#2D3E5F</color>
|
||||
<color name="shuttle_color_1f860d">#1F860D</color>
|
||||
<color name="shuttle_color_b9e7c0">#B9E7C0</color>
|
||||
<color name="shuttle_color_34A61F">#34A61F</color>
|
||||
<color name="shuttle_color_aeedb8">#AEEDB8</color>
|
||||
<color name="shuttle_color_43cefe">#43CEFE</color>
|
||||
<color name="shuttle_color_1466fb">#1466FB</color>
|
||||
<color name="shuttle_color_7094ad">#7094AD</color>
|
||||
</resources>
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
<string name="m2_over_map_style_path">m2_map_style.data</string>
|
||||
<string name="m2_over_map_style_extra_path">m2_map_style_extra.data</string>
|
||||
<string name="m2_p_auto_tv">Auto</string>
|
||||
<string name="m2_p_auto_tv">AUTO</string>
|
||||
<string name="m2_p_station_title_tv">下一站:</string>
|
||||
<string name="m2_p_station_title_arrived_tv">已到站</string>
|
||||
<string name="m2_p_empty_tv">暂无站点</string>
|
||||
@@ -22,7 +22,7 @@
|
||||
<string name="m2_p_empty_remain_km">—公里</string>
|
||||
<string name="m2_p_empty_remain_minute">—分钟</string>
|
||||
<string name="m2_p_arrived_station_title">请按秩序下车</string>
|
||||
<string name="m2_p_not_select_line_content">路线加载中…</string>
|
||||
<string name="m2_p_not_select_line_content">暂无路线</string>
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -28,6 +28,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -79,7 +79,6 @@ import com.mogo.och.common.module.voice.VoiceNotice;
|
||||
import com.mogo.och.common.module.bean.dpmsg.BusCacheKey;
|
||||
import com.mogo.och.data.bean.BusTransferData;
|
||||
import com.mogo.och.data.manager.cache.CacheDataManager;
|
||||
import com.zhidao.socket.utils.LoginStatusUtil;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@@ -767,7 +766,8 @@ public class OrderModel {
|
||||
// queryBusRoutes();
|
||||
// isArrivedStation = true;
|
||||
// isGoingToNextStation = false;
|
||||
// arriveStationSuccess(arrivedStationIndex, departureStopName, arriveStation);
|
||||
// arriveStationSuccess(arrivedStationIndex, departureStopName,
|
||||
// arriveStation,arriveStationKr);
|
||||
// }
|
||||
//5s轮询核销乘客
|
||||
// startOrStopQueryPassengerWriteOff(true);
|
||||
@@ -829,6 +829,7 @@ public class OrderModel {
|
||||
|
||||
private void pushCacheTransferData(BusRoutesResult result) {
|
||||
BusTransferData data = new BusTransferData(LoginStatusManager.isLogin() ? 1:0,result);
|
||||
CallerLogger.INSTANCE.d(M_BUS + TAG, "pushCacheTransferData = " + GsonUtils.toJson(data));
|
||||
CacheDataManager.Companion.getInstance().putCacheData(mContext,
|
||||
BusCacheKey.BUS_LINE_CACHE,
|
||||
GsonUtils.toJson(data));
|
||||
@@ -899,7 +900,8 @@ public class OrderModel {
|
||||
// //需要更改当前站和下一站的状态 然后渲染
|
||||
// //startOrStopQueryPassengerWriteOff(false);
|
||||
// queryBusRoutes();
|
||||
// leaveStationSuccess(backgroundCurrentStationIndex, currentStationName, finalNextStationName);
|
||||
// leaveStationSuccess(backgroundCurrentStationIndex, currentStationName,
|
||||
// finalNextStationName,finalNextStationNameKr);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -28,6 +28,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -5,6 +5,7 @@ import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
@@ -33,14 +34,25 @@ public class SweeperProvider implements IMogoOCH {
|
||||
}
|
||||
|
||||
private void showFragment() {
|
||||
FragmentManager supportFragmentManager = activity.getSupportFragmentManager();
|
||||
if (sweeperFragment == null) {
|
||||
CallerLogger.INSTANCE.d(TAG, "准备add fragment======");
|
||||
sweeperFragment = new SweeperFragment();
|
||||
activity.getSupportFragmentManager().beginTransaction().add(containerId, sweeperFragment).commitAllowingStateLoss();
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(SweeperFragment.TAG);
|
||||
if (fragmentByTag instanceof SweeperFragment){
|
||||
sweeperFragment = (SweeperFragment) fragmentByTag;
|
||||
}else {
|
||||
sweeperFragment = new SweeperFragment();
|
||||
}
|
||||
|
||||
if (!sweeperFragment.isAdded()){
|
||||
supportFragmentManager.beginTransaction().add(containerId, sweeperFragment
|
||||
,SweeperFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
CallerLogger.INSTANCE.d(TAG, "准备show fragment");
|
||||
activity.getSupportFragmentManager().beginTransaction().show(sweeperFragment).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().show(sweeperFragment).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
private void hideFragment() {
|
||||
|
||||
@@ -38,7 +38,7 @@ import java.util.Objects;
|
||||
*/
|
||||
public class SweeperFragment extends BaseSweeperTabFragment<SweeperFragment, SweeperPresenter>
|
||||
implements SlidePanelView.OnSlidePanelMoveToEndListener, View.OnClickListener {
|
||||
private static final String TAG = "SweeperFragment";
|
||||
public static final String TAG = "SweeperFragment";
|
||||
|
||||
private TextView mCurrentStationName;
|
||||
private TextView mNextStationName;
|
||||
|
||||
@@ -28,6 +28,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.commons.module.status.IMogoStatusChangedListener;
|
||||
@@ -48,14 +49,23 @@ class MogoOCHTaxiPassenger implements IMogoOCH {
|
||||
}
|
||||
|
||||
private void showFragment() {
|
||||
FragmentManager supportFragmentManager = mActivity.getSupportFragmentManager();
|
||||
if (ochTaxiPassengerFragment == null) {
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备add fragment======");
|
||||
ochTaxiPassengerFragment = new TaxiPassengerBaseFragment();
|
||||
mActivity.getSupportFragmentManager().beginTransaction().add(mContainerId, ochTaxiPassengerFragment).commitAllowingStateLoss();
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(TaxiPassengerBaseFragment.TAG);
|
||||
if (fragmentByTag instanceof TaxiPassengerBaseFragment){
|
||||
ochTaxiPassengerFragment = (TaxiPassengerBaseFragment) fragmentByTag;
|
||||
}else {
|
||||
ochTaxiPassengerFragment = new TaxiPassengerBaseFragment();
|
||||
}
|
||||
if (!ochTaxiPassengerFragment.isAdded()){
|
||||
supportFragmentManager.beginTransaction().add(mContainerId, ochTaxiPassengerFragment
|
||||
,TaxiPassengerBaseFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
return;
|
||||
}
|
||||
CallerLogger.INSTANCE.d(M_TAXI_P + TAG, "准备show fragment");
|
||||
mActivity.getSupportFragmentManager().beginTransaction().show(ochTaxiPassengerFragment).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().show(ochTaxiPassengerFragment).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
private void hideFragment() {
|
||||
|
||||
@@ -54,7 +54,7 @@ import java.util.Objects;
|
||||
public class TaxiPassengerBaseFragment extends MvpFragment<TaxiPassengerBaseFragment, BaseTaxiPassengerPresenter>
|
||||
implements IMogoMapListener, TaxiPassengerTaxiView, ITPClickStartAutopilotCallback{
|
||||
|
||||
static final String TAG = "TaxiPassengerBaseFragment";
|
||||
public static final String TAG = "TaxiPassengerBaseFragment";
|
||||
|
||||
private MapBizView mapBizView;
|
||||
private ImageView mAutopilotImage;
|
||||
|
||||
@@ -28,6 +28,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
minifyEnabled false
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentActivity;
|
||||
import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.function.call.setting.CallerMoGoUiSettingManager;
|
||||
@@ -44,14 +45,24 @@ class TaxiProvider implements IMogoOCH {
|
||||
}
|
||||
|
||||
private void showFragment() {
|
||||
FragmentManager supportFragmentManager = mActivity.getSupportFragmentManager();
|
||||
if (ochTaxiFragment == null) {
|
||||
CallerLogger.INSTANCE.d(M_TAXI + TAG, "准备add fragment======");
|
||||
ochTaxiFragment = new TaxiFragment();
|
||||
mActivity.getSupportFragmentManager().beginTransaction().add(mContainerId, ochTaxiFragment).commitAllowingStateLoss();
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(TaxiFragment.TAG);
|
||||
if (fragmentByTag instanceof TaxiFragment){
|
||||
ochTaxiFragment = (TaxiFragment) fragmentByTag;
|
||||
}else {
|
||||
ochTaxiFragment = new TaxiFragment();
|
||||
}
|
||||
|
||||
if (!ochTaxiFragment.isAdded()){
|
||||
supportFragmentManager.beginTransaction().add(mContainerId, ochTaxiFragment
|
||||
,TaxiFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
return;
|
||||
}
|
||||
CallerLogger.INSTANCE.d(M_TAXI + TAG, "准备show fragment");
|
||||
mActivity.getSupportFragmentManager().beginTransaction().show(ochTaxiFragment).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().show(ochTaxiFragment).commitAllowingStateLoss();
|
||||
}
|
||||
|
||||
private void hideFragment(){
|
||||
|
||||
@@ -198,6 +198,10 @@ android {
|
||||
targetCompatibility 1.8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = '1.8'
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
"shuttlepassengerm2": {
|
||||
"ads": [
|
||||
{
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1678946244305/dalim2.mp4",
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1681210902933/erhaim2.mp4",
|
||||
"type": 1,
|
||||
"cacheImgPath": "",
|
||||
"title": "1"
|
||||
@@ -143,7 +143,7 @@
|
||||
"shuttlepassengerm2": {
|
||||
"ads": [
|
||||
{
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1678946244305/dalim2.mp4",
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1681210902933/erhaim2.mp4",
|
||||
"type": 1,
|
||||
"cacheImgPath": "",
|
||||
"title": "1"
|
||||
@@ -155,17 +155,23 @@
|
||||
"shuttlepassenger": {
|
||||
"ads": [
|
||||
{
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1680774790614/yangmadao_photo.jpg",
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1681210971943/yangmadou.mp4",
|
||||
"type": 1,
|
||||
"cacheImgPath": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1680774847276/yangmadao_video.mp4",
|
||||
"cacheImgPath": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1680774790614/yangmadao_photo.jpg",
|
||||
"title": "1"
|
||||
},
|
||||
{
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1681210971943/yangmadou.mp4",
|
||||
"type": 1,
|
||||
"cacheImgPath": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1680774790614/yangmadao_photo.jpg",
|
||||
"title": "2"
|
||||
}
|
||||
]
|
||||
},
|
||||
"shuttlepassengerm2": {
|
||||
"ads": [
|
||||
{
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1678946244305/dalim2.mp4",
|
||||
"path": "https://img.zhidaohulian.com/fileServer/online_car_hailing/1681210902933/erhaim2.mp4",
|
||||
"type": 1,
|
||||
"cacheImgPath": "",
|
||||
"title": "1"
|
||||
|
||||
@@ -31,7 +31,7 @@ project.android.productFlavors {
|
||||
buildConfigField 'int', 'GPS_PROVIDER', "1"
|
||||
|
||||
// 构建的应用身份类型,具体查看 README.md APP_IDENTITY_MODE规则
|
||||
buildConfigField 'String', 'APP_IDENTITY_MODE', "\"Bus_Passenger_M2\""
|
||||
buildConfigField 'String', 'APP_IDENTITY_MODE', "\"Shuttle_Passenger_M2\""
|
||||
// 连接的工控机IP地址
|
||||
buildConfigField 'String', 'ADAS_CONNECT_IP', "\"192.168.8.103\""
|
||||
// 构建的是否是演示(美化)模式
|
||||
|
||||
@@ -96,11 +96,14 @@ object ConfigStartUp {
|
||||
HdMapBuildConfig.currentCarVrIconRes = R.raw.xiaobache
|
||||
} else if (AppIdentityModeUtils.isSweeper(FunctionBuildConfig.appIdentityMode)) {
|
||||
HdMapBuildConfig.currentCarVrIconRes = R.raw.huanwei
|
||||
} else if (AppIdentityModeUtils.isJL(FunctionBuildConfig.appIdentityMode)){
|
||||
}
|
||||
if (AppIdentityModeUtils.isJL(FunctionBuildConfig.appIdentityMode)){
|
||||
HdMapBuildConfig.currentCarVrIconRes = R.raw.xiaobache
|
||||
} else if (AppIdentityModeUtils.isM1(FunctionBuildConfig.appIdentityMode)){
|
||||
}
|
||||
if (AppIdentityModeUtils.isM1(FunctionBuildConfig.appIdentityMode)){
|
||||
HdMapBuildConfig.currentCarVrIconRes = R.raw.m1
|
||||
}else if (AppIdentityModeUtils.isM2(FunctionBuildConfig.appIdentityMode)) {
|
||||
}
|
||||
if (AppIdentityModeUtils.isM2(FunctionBuildConfig.appIdentityMode)) {
|
||||
HdMapBuildConfig.currentCarVrIconRes = R.raw.m2
|
||||
}
|
||||
|
||||
@@ -164,6 +167,12 @@ object ConfigStartUp {
|
||||
if (AppIdentityModeUtils.isBusPassenger(FunctionBuildConfig.appIdentityMode)) {
|
||||
mapParams.setShadowEnable(false)
|
||||
}
|
||||
if(AppIdentityModeUtils.isShuttlePassenger(FunctionBuildConfig.appIdentityMode)) {
|
||||
// shuttle m2 车需要偏移
|
||||
if (AppIdentityModeUtils.isM2(FunctionBuildConfig.appIdentityMode)) {
|
||||
mapParams.setCarPosition(-0.5f)
|
||||
}
|
||||
}
|
||||
|
||||
MapAutoApi.init(context, mapParams)
|
||||
|
||||
|
||||
@@ -42,6 +42,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = '1.8'
|
||||
}
|
||||
|
||||
@@ -207,13 +207,13 @@ class DispatchAutoPilotManager private constructor() :
|
||||
|
||||
fun affirm() {
|
||||
CallerHmiManager.dismissDispatchDialog()
|
||||
receiverBean?.taskId?.let {
|
||||
receiverBean?.taskId?.let { it ->
|
||||
dispatchServiceModel.dispatchResultUpload(DISPATCH_RESULT_AFFIRM, it,
|
||||
onSuccess = {
|
||||
//调用工控机开启自动驾驶
|
||||
startAutoPilot()
|
||||
},onError = {
|
||||
|
||||
},onError = { error->
|
||||
ToastUtils.showShort("上报调度失败${error}")
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -351,7 +351,9 @@ class DispatchAutoPilotManager private constructor() :
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_STEER,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_GEAR_SWITCH,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_CHASSIS_NO_RESPONSE,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_CHASSIS_UNKNOWN->{
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_CHASSIS_UNKNOWN,
|
||||
"IRECORDER_TASK_AUTO"//自动录包任务创建
|
||||
->{
|
||||
//如果到达终点,则不处理
|
||||
if(isArriveEnd){
|
||||
return
|
||||
|
||||
@@ -45,6 +45,11 @@ android {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -41,6 +41,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -12,7 +12,6 @@ class AiCloudSocketBizProvider : IMoGoFunctionServerProvider {
|
||||
get() = "AiCloudSocketBizProvider"
|
||||
|
||||
override fun init(context: Context?) {
|
||||
//todo bus加载
|
||||
context?.let {
|
||||
SocketManager.getInstance().init(it, 0.0, 0.0)
|
||||
SocketManager.getInstance().registerOnMessageListener(401012, V2XMessageListener401012())
|
||||
|
||||
@@ -569,7 +569,7 @@ class MogoObuDcCombineManager private constructor() : IMoGoObuWarningRsiListener
|
||||
CallerTrafficLightListenerManager.invokeTrafficLightPlusSource(
|
||||
TrafficLightEnum.BLACK,
|
||||
-1,
|
||||
DataSourceType.TELEMATIC
|
||||
DataSourceType.OBU
|
||||
)
|
||||
}
|
||||
// 红灯
|
||||
@@ -578,7 +578,7 @@ class MogoObuDcCombineManager private constructor() : IMoGoObuWarningRsiListener
|
||||
CallerTrafficLightListenerManager.invokeTrafficLightPlusSource(
|
||||
TrafficLightEnum.RED,
|
||||
red,
|
||||
DataSourceType.TELEMATIC
|
||||
DataSourceType.OBU
|
||||
)
|
||||
}
|
||||
// 绿灯
|
||||
@@ -587,7 +587,7 @@ class MogoObuDcCombineManager private constructor() : IMoGoObuWarningRsiListener
|
||||
CallerTrafficLightListenerManager.invokeTrafficLightPlusSource(
|
||||
TrafficLightEnum.GREEN,
|
||||
green,
|
||||
DataSourceType.TELEMATIC
|
||||
DataSourceType.OBU
|
||||
)
|
||||
}
|
||||
// 黄灯
|
||||
@@ -596,7 +596,7 @@ class MogoObuDcCombineManager private constructor() : IMoGoObuWarningRsiListener
|
||||
CallerTrafficLightListenerManager.invokeTrafficLightPlusSource(
|
||||
TrafficLightEnum.YELLOW,
|
||||
yellow,
|
||||
DataSourceType.TELEMATIC
|
||||
DataSourceType.OBU
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,6 +46,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
freeCompilerArgs += [
|
||||
|
||||
@@ -43,6 +43,10 @@ android {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -2061,11 +2061,11 @@ internal class DebugSettingView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
override fun onLogCatch(lineLog: String) {
|
||||
logInfoView?.let {
|
||||
if (logViewAttach) {
|
||||
it.onLogCatch(lineLog)
|
||||
}
|
||||
}
|
||||
// logInfoView?.let {
|
||||
// if (logViewAttach) {
|
||||
// it.onLogCatch(lineLog)
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
||||
private fun restartApp() {
|
||||
|
||||
@@ -9,7 +9,6 @@ import android.os.Process
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import android.view.View.OnTouchListener
|
||||
import android.widget.FrameLayout
|
||||
import com.mogo.eagle.core.data.app.AppConfigInfo
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotStatusInfo
|
||||
@@ -101,7 +100,23 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
|
||||
override fun onUpdate(inputContent: String?) {
|
||||
if (inputContent != null) {
|
||||
speedLimit = inputContent.toInt()
|
||||
try {
|
||||
if(inputContent.isEmpty()){
|
||||
speedLimit = 0
|
||||
}else{
|
||||
speedLimit = inputContent.toInt()
|
||||
if(speedLimit>60){
|
||||
speedLimit = 60
|
||||
ToastUtils.showShort("最大限速60")
|
||||
}
|
||||
}
|
||||
}catch (t: Exception){
|
||||
ToastUtils.showShort("最大限速60")
|
||||
speedLimit = 60
|
||||
|
||||
}
|
||||
etInputSpeed.setText(speedLimit.toString())
|
||||
etInputSpeed.setSelection(speedLimit.toString().length)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -150,6 +165,7 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
return@setOnTouchListener true
|
||||
}
|
||||
etInputSpeed.isFocusableInTouchMode = true
|
||||
etInputSpeed.setSelection(speedLimit.toString().length)
|
||||
if (keyBoardUtil == null) {
|
||||
keyBoardUtil = KeyBoardUtil(sKeyBoardView, etInputSpeed)
|
||||
}
|
||||
@@ -170,18 +186,26 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
if(speedLimit>=5){
|
||||
speedLimit -= 5
|
||||
etInputSpeed.setText(speedLimit.toString())
|
||||
}else{
|
||||
}else if(speedLimit in 1..4){
|
||||
speedLimit = 0
|
||||
etInputSpeed.setText(speedLimit.toString())
|
||||
} else{
|
||||
ToastUtils.showShort("车速不能再减了")
|
||||
}
|
||||
etInputSpeed.setSelection(speedLimit.toString().length)
|
||||
}
|
||||
|
||||
ivSpeedAdd.setOnClickListener {
|
||||
if(speedLimit<=55){
|
||||
speedLimit += 5
|
||||
etInputSpeed.setText(speedLimit.toString())
|
||||
}else{
|
||||
}else if(speedLimit in 56..59){
|
||||
speedLimit = 60
|
||||
etInputSpeed.setText(speedLimit.toString())
|
||||
} else{
|
||||
ToastUtils.showShort("车速不能再加了")
|
||||
}
|
||||
etInputSpeed.setSelection(speedLimit.toString().length)
|
||||
}
|
||||
|
||||
//速度确认
|
||||
@@ -202,6 +226,7 @@ internal class AutoPilotAndCheckView @JvmOverloads constructor(
|
||||
ToastUtils.showShort("设置车速失败,请启动域控制器")
|
||||
}
|
||||
}
|
||||
etInputSpeed.setSelection(speedLimit.toString().length)
|
||||
}
|
||||
|
||||
initOchView()
|
||||
|
||||
@@ -48,7 +48,7 @@ class BrakeViewStatus @JvmOverloads constructor(
|
||||
if (brakeLight == 1) { //刹车灯亮
|
||||
if (!isBrake) {
|
||||
isBrake = true
|
||||
CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(0, 500)
|
||||
CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(4, 500)
|
||||
GlobalScope.launch(Dispatchers.Main) {
|
||||
var appearAnimation = AlphaAnimation(0f, 1f)
|
||||
appearAnimation.duration = 300
|
||||
@@ -63,7 +63,7 @@ class BrakeViewStatus @JvmOverloads constructor(
|
||||
} else { //不踩刹车,就消失
|
||||
if (isBrake) {
|
||||
isBrake = false
|
||||
CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(3, 500)
|
||||
CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(0, 500)
|
||||
GlobalScope.launch(Dispatchers.Main) {
|
||||
// scaleImageAndTv()
|
||||
var disappearAnimation = AlphaAnimation(1f, 0f)
|
||||
|
||||
@@ -7,10 +7,15 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.data.enums.EventTypeEnumNew
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxBean
|
||||
import com.mogo.eagle.core.data.msgbox.MsgBoxType
|
||||
import com.mogo.eagle.core.data.msgbox.V2XMsg
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.api.hmi.warning.IMoGoWarningStatusListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
|
||||
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager
|
||||
import com.mogo.eagle.core.function.call.msgbox.CallerMsgBoxManager.saveMsgBox
|
||||
import com.mogo.eagle.core.function.hmi.R
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils
|
||||
import com.zhjt.mogo.adas.data.bean.MogoReport
|
||||
@@ -54,7 +59,7 @@ class TakeOverView @JvmOverloads constructor(
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_PLANNING,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_LOCATION,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_CHASSIS,
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_DISTANCE -> {
|
||||
MogoReport.Code.Error.EMAP.EXIT_AUTOPILOT_FOR_DISTANCE ->{
|
||||
CallerHmiManager.warningV2X(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
@@ -63,6 +68,46 @@ class TakeOverView @JvmOverloads constructor(
|
||||
override fun onShow() {
|
||||
takeOver = true
|
||||
visibility = View.VISIBLE
|
||||
//加入消息盒子
|
||||
saveMsgBox(
|
||||
MsgBoxBean(
|
||||
MsgBoxType.V2X, V2XMsg(
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.poiType,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.content,
|
||||
EventTypeEnumNew.TAKE_OVER_EVENT.tts
|
||||
)
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
takeOver = false
|
||||
visibility = View.GONE
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
//弱网
|
||||
MogoReport.Code.Error.EMAP.EPARALLEL_AICLOUD_NETWORK_WEAK,
|
||||
MogoReport.Code.Error.EMAP.EPARALLEL_AICLOUD_CONNECTION_ERROR -> {
|
||||
CallerHmiManager.warningV2X(
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.poiType,
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.content,
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.tts,
|
||||
object : IMoGoWarningStatusListener {
|
||||
override fun onShow() {
|
||||
takeOver = true
|
||||
visibility = View.VISIBLE
|
||||
//加入消息盒子
|
||||
saveMsgBox(
|
||||
MsgBoxBean(
|
||||
MsgBoxType.V2X, V2XMsg(
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.poiType,
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.content,
|
||||
EventTypeEnumNew.NETWORK_WEAK_EVENT.tts
|
||||
)
|
||||
)
|
||||
)
|
||||
}
|
||||
|
||||
override fun onDismiss() {
|
||||
|
||||
|
Before Width: | Height: | Size: 143 KiB After Width: | Height: | Size: 143 KiB |
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_393"
|
||||
android:layout_width="@dimen/dp_400"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#CCFFFFFF"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_393"
|
||||
android:layout_width="@dimen/dp_400"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#CCFFFFFF"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.eagle.core.widget.RoundCanClickConstraintLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/dp_393"
|
||||
android:layout_width="@dimen/dp_400"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="#CCFFFFFF"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.recyclerview.widget.RecyclerView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/rvMBoxBubbleList"
|
||||
android:layout_width="@dimen/dp_393"
|
||||
android:layout_width="@dimen/dp_400"
|
||||
android:layout_height="wrap_content"
|
||||
>
|
||||
|
||||
|
||||
@@ -1968,6 +1968,7 @@
|
||||
android:layout_margin="2dp"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:gravity="center"
|
||||
android:visibility="gone"
|
||||
android:textOff="展示日志过滤面板"
|
||||
android:textOn="关闭日志过滤面板"
|
||||
android:textSize="@dimen/dp_24" />
|
||||
|
||||
@@ -41,6 +41,11 @@ android {
|
||||
sourceCompatibility JavaVersion.VERSION_1_8
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -65,10 +65,10 @@ object TrackerSourceColorHelper {
|
||||
|
||||
//僵尸车
|
||||
if(data.addAttribute == AdditionalAttribute.ATTR_ZOMBIE){
|
||||
color = "#AD7488FF"
|
||||
color = "#7A8499FF"
|
||||
CallerMapUIServiceManager.getMapUIController()?.let {
|
||||
if(it.isDayMode){
|
||||
color = "#AE7887FF"
|
||||
color = "#9BA8BCFF"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -112,8 +112,8 @@ class MapBizView(context: Context?, attrs: AttributeSet?) : MogoMapView(context,
|
||||
private fun turn(lightNum: Int) {
|
||||
if (currentLevel != lightNum) {
|
||||
when (lightNum) {
|
||||
0 -> CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(3, 500)
|
||||
1 -> CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(4, 500)
|
||||
0 -> CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(0, 500)
|
||||
1 -> CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(1, 500)
|
||||
2 -> CallerMapUIServiceManager.getMapUIController()?.setCarLightsType(2, 500)
|
||||
}
|
||||
currentLevel = lightNum
|
||||
|
||||
@@ -145,6 +145,7 @@ class OverMapView @JvmOverloads constructor(
|
||||
topPadding = typedArray.getInt(R.styleable.OverMapView_topPadding, 100)
|
||||
rightPadding = typedArray.getInt(R.styleable.OverMapView_rightPadding, 100)
|
||||
bottomPadding = typedArray.getInt(R.styleable.OverMapView_bottomPadding, 100)
|
||||
mTilt = typedArray.getFloat(R.styleable.OverMapView_mapTilt, 30f)
|
||||
typedArray.recycle()
|
||||
initView(context)
|
||||
} catch (e: Exception) {
|
||||
@@ -296,7 +297,6 @@ class OverMapView @JvmOverloads constructor(
|
||||
|
||||
private fun initAMapView(context: Context) {
|
||||
Log.d(TAG, "initAMapView")
|
||||
mTilt = 30f
|
||||
mCameraUpdate = CameraUpdateFactory.zoomTo(zoomLevel.toFloat())
|
||||
mAMap = mMapView!!.map
|
||||
mCustomMapStyleOptions = CustomMapStyleOptions()
|
||||
|
||||
@@ -29,5 +29,7 @@
|
||||
<attr name="topPadding" format="integer" />
|
||||
<attr name="rightPadding" format="integer" />
|
||||
<attr name="bottomPadding" format="integer" />
|
||||
<!-- 倾斜角 -->
|
||||
<attr name="mapTilt" format="float" />
|
||||
</declare-styleable>
|
||||
</resources>
|
||||
@@ -35,6 +35,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
@@ -47,6 +47,10 @@ android {
|
||||
targetCompatibility JavaVersion.VERSION_1_8
|
||||
}
|
||||
|
||||
lintOptions {
|
||||
abortOnError false
|
||||
}
|
||||
|
||||
protobuf {
|
||||
protoc {
|
||||
artifact = rootProject.ext.dependencies.protoc
|
||||
|
||||