[6.4.0]
[taxi 样式调整]
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_connect_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="当前状态:连接司机屏中"
|
||||
android:textColor="@color/white"
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_app_version"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_41"
|
||||
android:layout_marginStart="@dimen/dp_160"
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_connect_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintBottom_toTopOf="@+id/actv_app_version"
|
||||
android:text="当前状态:连接司机屏中"
|
||||
@@ -18,7 +18,7 @@
|
||||
android:layout_marginStart="@dimen/dp_160"
|
||||
android:layout_marginEnd="@dimen/dp_160"
|
||||
android:textSize="@dimen/dp_24"
|
||||
android:gravity="end"
|
||||
android:gravity="center"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_chainStyle="packed"
|
||||
@@ -26,12 +26,13 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_app_version"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/dp_41"
|
||||
android:layout_marginStart="@dimen/dp_160"
|
||||
android:layout_marginEnd="@dimen/dp_160"
|
||||
android:text="版本号:6.4.0"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/dp_24"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
|
||||
@@ -10,10 +10,11 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_connect_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="当前状态:连接司机屏中"
|
||||
android:textColor="@color/white"
|
||||
android:gravity="center"
|
||||
android:textSize="@dimen/dp_26"
|
||||
android:layout_marginStart="@dimen/dp_160"
|
||||
android:layout_marginEnd="@dimen/dp_160"
|
||||
@@ -24,8 +25,9 @@
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/actv_app_version"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:layout_marginBottom="@dimen/dp_70"
|
||||
android:layout_marginStart="@dimen/dp_160"
|
||||
android:layout_marginEnd="@dimen/dp_160"
|
||||
|
||||
@@ -44,7 +44,7 @@ public interface ITaxiOrderStatusCallback {
|
||||
void onGrabOrderFailed(OrderQueryRespBean.Result order);
|
||||
|
||||
// 司机已确认开启自动驾驶环境
|
||||
void onDriverHasCheckedPilotCondition(boolean isSafe);
|
||||
void onDriverHasCheckedPilotCondition();
|
||||
|
||||
/**
|
||||
* 导航到目的地
|
||||
|
||||
@@ -762,7 +762,7 @@ public class TaxiModel {
|
||||
* 2.server去除订单流转对"安全确认"的限制(读写接口默认反馈ok,但"开启自动驾驶成功"不再限制)
|
||||
*/
|
||||
// updateAutopilotStatus(data.code == 0);
|
||||
updateAutopilotStatus(true);
|
||||
updateAutopilotStatus();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -771,14 +771,14 @@ public class TaxiModel {
|
||||
* 2.server去除订单流转对"安全确认"的限制(读写接口默认反馈ok,但"开启自动驾驶成功"不再限制)
|
||||
*/
|
||||
// updateAutopilotStatus(false);
|
||||
updateAutopilotStatus(true);
|
||||
updateAutopilotStatus();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void updateAutopilotStatus(boolean isSafe) {
|
||||
public void updateAutopilotStatus() {
|
||||
if (mOrderStatusCallback != null) {
|
||||
mOrderStatusCallback.onDriverHasCheckedPilotCondition(isSafe);
|
||||
mOrderStatusCallback.onDriverHasCheckedPilotCondition();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -798,7 +798,7 @@ public class TaxiModel {
|
||||
* 2.server去除订单流转对"安全确认"的限制(读写接口默认反馈ok,但"开启自动驾驶成功"不再限制)
|
||||
*/
|
||||
// updateAutopilotStatus(data.data.equals(true));
|
||||
updateAutopilotStatus(true);
|
||||
updateAutopilotStatus();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -807,7 +807,7 @@ public class TaxiModel {
|
||||
* 2.server去除订单流转对"安全确认"的限制(读写接口默认反馈ok,但"开启自动驾驶成功"不再限制)
|
||||
*/
|
||||
// updateAutopilotStatus(false);
|
||||
updateAutopilotStatus(true);
|
||||
updateAutopilotStatus();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -321,8 +321,8 @@ public class TaxiPresenter extends Presenter<TaxiFragment> implements ITaxiADASS
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDriverHasCheckedPilotCondition(boolean isSafe) {
|
||||
runOnUIThread(() -> mView.onCheckPilotConditionSafe(isSafe));
|
||||
public void onDriverHasCheckedPilotCondition() {
|
||||
runOnUIThread(() -> mView.onCheckPilotConditionSafe());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -325,11 +325,9 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
ctvAutopilotStatusRL.setTag(tag);
|
||||
}
|
||||
|
||||
public void onCheckPilotConditionSafe(boolean isSafe) {
|
||||
updateCtvAutopilotStatusTag(isSafe);
|
||||
if (isSafe) {
|
||||
updateOrderBottomBtnUI();
|
||||
}
|
||||
public void onCheckPilotConditionSafe() {
|
||||
updateCtvAutopilotStatusTag(true);
|
||||
updateOrderBottomBtnUI();
|
||||
}
|
||||
|
||||
protected abstract void updateOrderBottomBtnUI();
|
||||
|
||||
@@ -66,9 +66,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
private ImageView mOrderCancel;
|
||||
|
||||
private TextView mOrderServerStatus;
|
||||
private ConstraintLayout mOrderStartModeBtn;
|
||||
private TextView mAutoPilotBtn;
|
||||
private TextView mManualBtn;
|
||||
|
||||
private ConstraintLayout mBeingOrderLayout;
|
||||
private ConstraintLayout mContentModule3;
|
||||
@@ -120,9 +117,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
mOrderCancel = view.findViewById(R.id.module_och_taxi_order_cancel_iv);
|
||||
|
||||
mOrderServerStatus = view.findViewById(R.id.module_och_taxi_order_server_status_tv);
|
||||
mOrderStartModeBtn = view.findViewById(R.id.taxi_start_mode_btn);
|
||||
mAutoPilotBtn = view.findViewById(R.id.taxi_start_by_auto);
|
||||
mManualBtn = view.findViewById(R.id.taxi_start_by_manual);
|
||||
|
||||
mBeingOrderLayout = view.findViewById(R.id.module_och_taxi_being_order_content);
|
||||
mContentModule2 = view.findViewById(R.id.module_och_taxi_order_status_station_2);
|
||||
@@ -161,8 +155,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
private void initOnClickListener() {
|
||||
mOrderCancel.setOnClickListener(this);
|
||||
mOrderServerStatus.setOnClickListener(this);
|
||||
mAutoPilotBtn.setOnClickListener(this);
|
||||
mManualBtn.setOnClickListener(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -203,7 +195,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
mContentModule3.setVisibility(View.GONE);
|
||||
mContentModule2.setVisibility(View.VISIBLE);
|
||||
CallerLogger.d(M_TAXI + TAG, "已经达到终点");
|
||||
mOrderStatus.setText(R.string.module_och_taxi_arrive_at_end_station2);
|
||||
updateOrderBottomBtn(getString(R.string.module_och_taxi_order_server_end),
|
||||
Color.parseColor("#FFFFFF"),
|
||||
Color.parseColor("#FF1D5EF3"),
|
||||
@@ -289,7 +280,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
// showOrHideOrderModeBtn(true);
|
||||
showOrHideOrderModeBtn(false);
|
||||
CallerLogger.d(M_TAXI + TAG, "自驾模式");
|
||||
mOrderStartModeBtn.setTag(0);
|
||||
startOrEndService();
|
||||
}
|
||||
|
||||
@@ -341,10 +331,8 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
|
||||
private void showOrHideOrderModeBtn(boolean isShow) {
|
||||
if (isShow){
|
||||
mOrderStartModeBtn.setVisibility(View.VISIBLE);
|
||||
mOrderServerStatus.setVisibility(View.GONE);
|
||||
}else {
|
||||
mOrderStartModeBtn.setVisibility(View.GONE);
|
||||
mOrderServerStatus.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
@@ -629,14 +617,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
if (mTaxiFragment != null) {
|
||||
showNaviToEndStationFragment(true);
|
||||
}
|
||||
}else if (v.getId() == R.id.taxi_start_by_auto){//自驾模式
|
||||
CallerLogger.d(M_TAXI + TAG, "自驾模式");
|
||||
mOrderStartModeBtn.setTag(0);
|
||||
startOrEndService();
|
||||
} else if (v.getId() == R.id.taxi_start_by_manual){//人工模式
|
||||
CallerLogger.d(M_TAXI + TAG, "人工模式");
|
||||
mOrderStartModeBtn.setTag(1);
|
||||
mTaxiFragment.confirmAutopilotConditionByDriver();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -795,10 +775,6 @@ public class TaxiBeingServerdOrdersFragment extends BaseTaxiUIFragment
|
||||
|
||||
public void updateOrderBottomBtnUI() {
|
||||
try {
|
||||
if ((int)mOrderStartModeBtn.getTag() == 1){//人工
|
||||
mTaxiFragment.startManualDirve();
|
||||
return;
|
||||
}
|
||||
ToastUtils.showLong(getResources().getString(
|
||||
R.string.module_och_taxi_order_choose_start_autopilot_tip));
|
||||
showOrHideOrderModeBtn(false);
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 70 KiB |
@@ -1,33 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="@dimen/module_och_taxi_panel_width"
|
||||
android:layout_height="130dp"
|
||||
android:id="@+id/taxi_start_mode_btn"
|
||||
android:visibility="gone"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="@drawable/order_drive_mode_bg">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/taxi_start_by_auto"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginLeft="@dimen/dp_40"
|
||||
android:text="@string/och_taxi_auto_txt"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="@dimen/dp_48"/>
|
||||
<TextView
|
||||
android:id="@+id/taxi_start_by_manual"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
android:text="@string/och_taxi_manual_txt"
|
||||
android:layout_marginRight="@dimen/dp_40"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="@dimen/dp_48"/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -94,7 +94,6 @@
|
||||
android:id="@+id/module_och_taxi_order_distance_anchor_2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="264dp"
|
||||
android:inputType="textMultiLine"
|
||||
android:lineSpacingExtra="16dp"
|
||||
android:text="距离 - - 公里,用时 - - 分"
|
||||
@@ -269,6 +268,7 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/module_och_taxi_order_distance_anchor_3"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_taxi_order_other_content_3"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="180dp"
|
||||
@@ -277,7 +277,6 @@
|
||||
android:text="距离 -- 公里,用时 -- 分钟"
|
||||
android:textColor="#CAD6FF"
|
||||
android:textSize="32dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/module_och_taxi_order_go_ahead_station_31"/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -293,12 +292,6 @@
|
||||
android:textSize="@dimen/dp_48"
|
||||
app:layout_constraintBottom_toBottomOf="parent" />
|
||||
|
||||
<include layout="@layout/auto_or_manual_btn_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="130dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
<include
|
||||
|
||||
@@ -29,7 +29,9 @@
|
||||
<androidx.viewpager.widget.ViewPager
|
||||
android:id="@+id/module_och_taxi_view_pager"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="798dp"
|
||||
android:layout_height="@dimen/dp_900"
|
||||
android:paddingStart="@dimen/dp_29"
|
||||
android:paddingEnd="@dimen/dp_29"
|
||||
android:overScrollMode="never"
|
||||
android:background="@drawable/taxi_order_viewpager_bg"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_taxi_tab"
|
||||
|
||||
Reference in New Issue
Block a user