From fbe11c22c498fc266bc852ed7843c19c4bc192fd Mon Sep 17 00:00:00 2001 From: wangmingjun Date: Fri, 14 Oct 2022 19:58:52 +0800 Subject: [PATCH] =?UTF-8?q?[2.11.0]=20[fix]1=E3=80=81bus=20=E5=B0=8F?= =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E6=B8=85=E9=99=A4=E8=BD=A8=E8=BF=B9=202?= =?UTF-8?q?=E3=80=81taxi=E8=87=AA=E9=A9=BE=E6=8C=89=E9=92=AE=E6=98=BE?= =?UTF-8?q?=E7=A4=BAbug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../passenger/ui/BusPassengerBaseFragment.java | 1 + .../ui/BusPassengerMapDirectionView.java | 2 +- .../passenger/ui/BusPassengerRouteFragment.java | 17 ++++++++--------- .../mogo/och/bus/presenter/BusPresenter.java | 1 + .../java/com/mogo/och/taxi/model/TaxiModel.java | 6 +++--- 5 files changed, 14 insertions(+), 13 deletions(-) diff --git a/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerBaseFragment.java b/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerBaseFragment.java index 143e4d1cc4..c9abd42c76 100644 --- a/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerBaseFragment.java +++ b/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerBaseFragment.java @@ -105,6 +105,7 @@ public abstract class BusPassengerBaseFragment 2) { + if (mLinePointsLatLng.size() > 2) { //设置线段纹理 PolylineOptions polylineOptions = new PolylineOptions(); diff --git a/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerRouteFragment.java b/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerRouteFragment.java index 4f5d0d0451..dfc9495007 100644 --- a/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerRouteFragment.java +++ b/OCH/mogo-och-bus-passenger/src/main/java/com/mogo/och/bus/passenger/ui/BusPassengerRouteFragment.java @@ -148,7 +148,7 @@ public class BusPassengerRouteFragment extends if (latLngList.size() > 0) { drawablePolyline(latLngList,haveArrivedIndex); } else { - clearPolyline(); + clearMapView(); } } @@ -164,7 +164,7 @@ public class BusPassengerRouteFragment extends }); } } else { - clearPolyline(); + clearMapView(); } } @@ -185,13 +185,13 @@ public class BusPassengerRouteFragment extends } } - public void clearPolyline() { + public void clearMapView() { if (mMapDirectionView != null) { UiThreadHandler.post(new Runnable() { @Override public void run() { mMapDirectionView.clearPolyline(); - + mMapDirectionView.clearCoordinatesLatLng(); } }); } @@ -230,7 +230,7 @@ public class BusPassengerRouteFragment extends mNoLineInfoView.setVisibility(View.VISIBLE); mRouteInfoView.setVisibility(View.GONE); updateArrivedStation(null,0,true); - clearPolyline(); + clearMapView(); clearMapMarkers(); } } @@ -240,10 +240,10 @@ public class BusPassengerRouteFragment extends mNoLineInfoView.setVisibility(View.VISIBLE); mRouteInfoView.setVisibility(View.GONE); updateArrivedStation(null,0,true); - clearPolyline(); + clearMapView(); clearMapMarkers(); } - emptyTv.setText(getString(R.string.bus_p_no_task)); + emptyTv.setText(getString(R.string.bus_p_no_task)); } public void hideNoTaskView(){ @@ -285,8 +285,7 @@ public class BusPassengerRouteFragment extends if (currentStationIndex == 0 && isArrived){ //到达始发站且并未出发, 恢复站点marker 清楚路径 清空路径点 SharedPrefsMgr.getInstance(getContext()) .remove(BusPassengerConst.BUS_SP_KEY_ORDER_SUM_DIS); - if (mMapDirectionView != null) mMapDirectionView.clearCoordinatesLatLng(); - clearPolyline(); + clearMapView(); } if (stations.size() > 0){ diff --git a/OCH/mogo-och-bus/src/main/java/com/mogo/och/bus/presenter/BusPresenter.java b/OCH/mogo-och-bus/src/main/java/com/mogo/och/bus/presenter/BusPresenter.java index b0b1f3023e..fdb55d3a36 100644 --- a/OCH/mogo-och-bus/src/main/java/com/mogo/och/bus/presenter/BusPresenter.java +++ b/OCH/mogo-och-bus/src/main/java/com/mogo/och/bus/presenter/BusPresenter.java @@ -156,6 +156,7 @@ public class BusPresenter extends Presenter @Override public void onAutopilotArriveAtStation(MessagePad.ArrivalNotification arrivalNotification) { + CallerLogger.INSTANCE.e( M_BUS + TAG, "onAutopilotArriveAtStation arrive"); BusOrderModel.getInstance().onArriveAt(arrivalNotification); } diff --git a/OCH/mogo-och-taxi/src/main/java/com/mogo/och/taxi/model/TaxiModel.java b/OCH/mogo-och-taxi/src/main/java/com/mogo/och/taxi/model/TaxiModel.java index 45a0278c55..9c1fc34c0c 100644 --- a/OCH/mogo-och-taxi/src/main/java/com/mogo/och/taxi/model/TaxiModel.java +++ b/OCH/mogo-och-taxi/src/main/java/com/mogo/och/taxi/model/TaxiModel.java @@ -1162,7 +1162,7 @@ public class TaxiModel { // 当美化模式(演示模式)开启时:且有订单、且为去往目的地状态,维持自动驾驶icon开启状态 return; } - if (state != mPrevAPStatus && mADASStatusCallback != null){ + if (mADASStatusCallback != null){ mADASStatusCallback.onAutopilotEnable(); } mPrevAPStatus = state; @@ -1174,7 +1174,7 @@ public class TaxiModel { // 当美化模式(演示模式)开启时:且有订单、且为去往目的地状态,维持自动驾驶icon开启状态 return; } - if (state != mPrevAPStatus && mADASStatusCallback != null){ + if (mADASStatusCallback != null){ mADASStatusCallback.onAutopilotDisable(); } mPrevAPStatus = state; @@ -1192,7 +1192,7 @@ public class TaxiModel { } return; } - if (state != mPrevAPStatus && mADASStatusCallback != null){ + if (mADASStatusCallback != null){ mADASStatusCallback.onManMachineCoDriving(); } mPrevAPStatus = state;