[6.3.0]
[shuttle driver 因 核销人数变更]
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
|
||||
package com.mogo.och.bus;
|
||||
|
||||
import static com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.M_BUS;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
@@ -11,10 +9,9 @@ import androidx.fragment.app.FragmentManager;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.function.api.base.IMoGoFunctionProvider;
|
||||
import com.mogo.eagle.core.function.call.setting.CallerMoGoUiSettingManager;
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger;
|
||||
import com.mogo.och.bus.constant.BusConst;
|
||||
import com.mogo.och.bus.fragment.BusFragment;
|
||||
import com.mogo.och.bus.fragment.ShuttleFragment;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
@@ -29,7 +26,7 @@ public class BusProvider implements IMoGoFunctionProvider {
|
||||
|
||||
private static final String TAG = "BusProvider";
|
||||
|
||||
private BusFragment busFragment;
|
||||
private ShuttleFragment busFragment;
|
||||
private int containerId;
|
||||
private FragmentActivity activity;
|
||||
|
||||
@@ -41,14 +38,14 @@ public class BusProvider implements IMoGoFunctionProvider {
|
||||
FragmentManager supportFragmentManager = activity.getSupportFragmentManager();
|
||||
if (busFragment == null) {
|
||||
CallerLogger.d(TAG, "准备add fragment======");
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(BusFragment.TAG);
|
||||
if (fragmentByTag instanceof BusFragment) {
|
||||
busFragment = (BusFragment) fragmentByTag;
|
||||
Fragment fragmentByTag = supportFragmentManager.findFragmentByTag(ShuttleFragment.TAG);
|
||||
if (fragmentByTag instanceof ShuttleFragment) {
|
||||
busFragment = (ShuttleFragment) fragmentByTag;
|
||||
} else {
|
||||
busFragment = new BusFragment();
|
||||
busFragment = new ShuttleFragment();
|
||||
}
|
||||
if(!busFragment.isAdded()) {
|
||||
supportFragmentManager.beginTransaction().add(containerId, busFragment, BusFragment.TAG).commitAllowingStateLoss();
|
||||
supportFragmentManager.beginTransaction().add(containerId, busFragment, ShuttleFragment.TAG).commitAllowingStateLoss();
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -43,6 +43,7 @@ import com.mogo.map.listener.MogoMapListenerHandler;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.och.bus.R;
|
||||
import com.mogo.och.bus.ui.ShuttleTrafficDataView;
|
||||
import com.mogo.och.bus.view.BizMapView;
|
||||
import com.mogo.och.data.bean.BusRoutesResult;
|
||||
import com.mogo.och.bus.model.OrderModel;
|
||||
@@ -57,7 +58,7 @@ import org.greenrobot.eventbus.EventBus;
|
||||
*
|
||||
* @author tongchenfei
|
||||
*/
|
||||
public abstract class BaseBusTabFragment<V extends IView, P extends Presenter<V>> extends MvpFragment<V, P> implements IMogoMapListener {
|
||||
public abstract class BaseShuttleTabFragment<V extends IView, P extends Presenter<V>> extends MvpFragment<V, P> implements IMogoMapListener {
|
||||
|
||||
private static final String TAG = "BaseBusTabFragment";
|
||||
|
||||
@@ -72,7 +73,7 @@ public abstract class BaseBusTabFragment<V extends IView, P extends Presenter<V>
|
||||
private FrameLayout flStationPanelContainer;
|
||||
private BizMapView mapBizView;
|
||||
private Group groupTestPanel;
|
||||
private TrafficDataView mTrafficDataView;
|
||||
private ShuttleTrafficDataView mTrafficDataView;
|
||||
// private BusTrafficLightView mTrafficLightView;
|
||||
|
||||
//远景和中景的切换
|
||||
@@ -102,7 +103,7 @@ public abstract class BaseBusTabFragment<V extends IView, P extends Presenter<V>
|
||||
|
||||
@Override
|
||||
protected int getLayoutId() {
|
||||
return R.layout.bus_base_fragment;
|
||||
return R.layout.shuttle_base_fragment;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -121,7 +122,7 @@ public abstract class BaseBusTabFragment<V extends IView, P extends Presenter<V>
|
||||
// tvOperationStatus = findViewById(R.id.module_mogo_och_operation_status);
|
||||
tvArrived = findViewById(R.id.module_mogo_och_arrived_tv);
|
||||
|
||||
mTrafficDataView = (TrafficDataView) findViewById(R.id.bus_arc);
|
||||
mTrafficDataView = (ShuttleTrafficDataView) findViewById(R.id.bus_arc);
|
||||
|
||||
LayoutInflater.from(getContext()).inflate(getStationPanelViewId(), flStationPanelContainer);
|
||||
slidePanelView.setOnSlidePanelMoveToEndListener(onSlideToEndListener);
|
||||
@@ -60,7 +60,7 @@ import me.jessyan.autosize.utils.AutoSizeUtils;
|
||||
*
|
||||
* @author tongchenfei
|
||||
*/
|
||||
public class BusFragment extends BaseBusTabFragment<BusFragment, BusPresenter>
|
||||
public class ShuttleFragment extends BaseShuttleTabFragment<ShuttleFragment, BusPresenter>
|
||||
implements SlidePanelView.OnSlidePanelMoveToEndListener, View.OnClickListener {
|
||||
public static final String TAG = "BusFragment";
|
||||
|
||||
@@ -21,7 +21,7 @@ import com.mogo.och.bus.callback.IBusADASStatusCallback;
|
||||
import com.mogo.och.bus.callback.IBusControllerStatusCallback;
|
||||
import com.mogo.och.bus.callback.IRefreshBusStationsCallback;
|
||||
import com.mogo.och.bus.callback.ISlidePannelHideCallback;
|
||||
import com.mogo.och.bus.fragment.BusFragment;
|
||||
import com.mogo.och.bus.fragment.ShuttleFragment;
|
||||
import com.mogo.och.bus.model.OrderModel;
|
||||
import com.mogo.och.bus.util.BusTrajectoryManager;
|
||||
import com.mogo.och.common.module.biz.bean.DriverStatusQueryRespBean;
|
||||
@@ -44,7 +44,7 @@ import system_master.SystemStatusInfo;
|
||||
*
|
||||
* @author tongchenfei
|
||||
*/
|
||||
public class BusPresenter extends Presenter<BusFragment>
|
||||
public class BusPresenter extends Presenter<ShuttleFragment>
|
||||
implements IRefreshBusStationsCallback, ISlidePannelHideCallback
|
||||
, IMoGoAutopilotStatusListener, IBusControllerStatusCallback, ILoginCallback, IBusADASStatusCallback {
|
||||
|
||||
@@ -53,7 +53,7 @@ public class BusPresenter extends Presenter<BusFragment>
|
||||
private final List<BusStationBean> mStationList = new ArrayList<>();
|
||||
private int mCurrentStation = 0;
|
||||
|
||||
public BusPresenter(BusFragment view) {
|
||||
public BusPresenter(ShuttleFragment view) {
|
||||
super(view);
|
||||
//2021.11.1 鹰眼架构整合,由IMoGoAutopilotStatusListener逐步替代IMogoAdasOCHCallback接口
|
||||
CallerAutoPilotStatusListenerManager.INSTANCE.addListener(TAG, this);
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
package com.mogo.och.bus.ui;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig;
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils;
|
||||
import com.mogo.och.bus.R;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import chassis.Chassis;
|
||||
|
||||
/**
|
||||
* @author Jing
|
||||
* @description 方向盘下方的档位
|
||||
* @since: 4/7/22
|
||||
*/
|
||||
public class ShuttleTapPositionView extends ConstraintLayout {
|
||||
private static final String TAG = "TapPositionView";
|
||||
private TextView tabP;
|
||||
private TextView tabR;
|
||||
private TextView tabN;
|
||||
private TextView tabD;
|
||||
private TypedArray typedArray;
|
||||
|
||||
public ShuttleTapPositionView(Context context, @Nullable AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
LayoutInflater.from(context).inflate(R.layout.shuttle_tap_position, this);
|
||||
tabP = findViewById(R.id.tap_p);
|
||||
tabR = findViewById(R.id.tap_r);
|
||||
tabN = findViewById(R.id.tap_n);
|
||||
tabD = findViewById(R.id.tap_d);
|
||||
typedArray = context.obtainStyledAttributes(attrs, R.styleable.TapPositionView);
|
||||
if(AppIdentityModeUtils.isBus(FunctionBuildConfig.appIdentityMode)||AppIdentityModeUtils.isSweeper(FunctionBuildConfig.appIdentityMode)){
|
||||
tabP.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
public void updateWithGear(@NotNull Chassis.GearPosition gear) {
|
||||
if (tabP != null && tabR != null && tabN != null && tabD != null) {
|
||||
int defaultColor = typedArray.getColor(R.styleable.TapPositionView_defaultColor, -1);
|
||||
int selectColor = typedArray.getColor(R.styleable.TapPositionView_selectColor, -1);
|
||||
switch (gear) {
|
||||
case GEAR_NONE:
|
||||
tabP.setTextColor(defaultColor);
|
||||
tabR.setTextColor(defaultColor);
|
||||
tabN.setTextColor(defaultColor);
|
||||
tabD.setTextColor(defaultColor);
|
||||
break;
|
||||
case GEAR_P:
|
||||
tabP.setTextColor(selectColor);
|
||||
tabR.setTextColor(defaultColor);
|
||||
tabN.setTextColor(defaultColor);
|
||||
tabD.setTextColor(defaultColor);
|
||||
break;
|
||||
case GEAR_R:
|
||||
tabR.setTextColor(selectColor);
|
||||
tabP.setTextColor(defaultColor);
|
||||
tabN.setTextColor(defaultColor);
|
||||
tabD.setTextColor(defaultColor);
|
||||
break;
|
||||
case GEAR_N:
|
||||
tabN.setTextColor(selectColor);
|
||||
tabR.setTextColor(defaultColor);
|
||||
tabP.setTextColor(defaultColor);
|
||||
tabD.setTextColor(defaultColor);
|
||||
break;
|
||||
case GEAR_D:
|
||||
tabD.setTextColor(selectColor);
|
||||
tabN.setTextColor(defaultColor);
|
||||
tabR.setTextColor(defaultColor);
|
||||
tabP.setTextColor(defaultColor);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,170 @@
|
||||
package com.mogo.och.bus.ui;
|
||||
|
||||
import static com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_RUNNING;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.content.Context;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.util.AttributeSet;
|
||||
import android.view.LayoutInflater;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotPlanningActionsListener;
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisBrakeStateListener;
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisGearStateListener;
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisThrottleStateListener;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisBrakeStateListenerManager;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisGearStateListenerManager;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisThrottleStateListenerManager;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerPlanningActionsListenerManager;
|
||||
import com.mogo.eagle.core.function.hmi.ui.widget.TapPositionView;
|
||||
import com.mogo.eagle.core.utilcode.util.ThreadUtils;
|
||||
import com.mogo.och.bus.R;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import chassis.Chassis;
|
||||
import mogo.telematics.pad.MessagePad;
|
||||
|
||||
/**
|
||||
* @author Jing
|
||||
* @description 速度 加速度 档位 刹车 油门状态值
|
||||
* @since: 6/24/22
|
||||
*/
|
||||
public class ShuttleTrafficDataView extends ConstraintLayout implements
|
||||
IMoGoChassisGearStateListener ,
|
||||
IMoGoChassisBrakeStateListener,
|
||||
IMoGoChassisThrottleStateListener,
|
||||
IMoGoAutopilotPlanningActionsListener {
|
||||
private static final String TAG = "TrafficDataView";
|
||||
private ShuttleTapPositionView tapPositionView;
|
||||
private TextView speedTextView;
|
||||
private TextView accTextView;
|
||||
private ImageView speedImage;
|
||||
private ImageView brakeStatus;
|
||||
|
||||
private static final int MSG_SEND_UPDATE = 1;
|
||||
private volatile double acceleration;
|
||||
private volatile float mBrake;
|
||||
private volatile float mThrottle;
|
||||
|
||||
@SuppressLint("HandlerLeak")
|
||||
private final Handler handler = new Handler() {
|
||||
@Override
|
||||
public void handleMessage(@NonNull Message msg) {
|
||||
super.handleMessage(msg);
|
||||
if (msg.what == MSG_SEND_UPDATE) {
|
||||
java.text.DecimalFormat mFormat = new java.text.DecimalFormat("0.0");
|
||||
String accStr = mFormat.format(Math.abs(acceleration));
|
||||
if (acceleration > 0f) {
|
||||
accTextView.setText(accStr);
|
||||
} else {
|
||||
accTextView.setText("- " + accStr);
|
||||
}
|
||||
int state = CallerAutoPilotStatusListenerManager.INSTANCE.getState();
|
||||
if (state < STATUS_AUTOPILOT_RUNNING) {
|
||||
if (mBrake > 0) {
|
||||
brakeStatus.setImageResource(R.drawable.traffic_data_brake);
|
||||
} else if (mThrottle >= 0 && mBrake == 0) {
|
||||
brakeStatus.setImageResource(R.drawable.traffic_data_accelerator);
|
||||
} else {
|
||||
brakeStatus.setImageResource(R.drawable.traffic_data_empty);
|
||||
}
|
||||
}
|
||||
if (state == 2) {
|
||||
brakeStatus.setImageResource(R.drawable.traffic_data_empty);
|
||||
}
|
||||
}
|
||||
handler.sendEmptyMessageDelayed(MSG_SEND_UPDATE, 1000L);
|
||||
}
|
||||
};
|
||||
|
||||
public ShuttleTrafficDataView(@NonNull Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
public ShuttleTrafficDataView(@NonNull Context context, @Nullable AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
initView(context);
|
||||
}
|
||||
|
||||
public ShuttleTrafficDataView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
|
||||
super(context, attrs, defStyleAttr);
|
||||
}
|
||||
|
||||
public ShuttleTrafficDataView(@NonNull Context context, @Nullable AttributeSet attrs, int defStyleAttr, int defStyleRes) {
|
||||
super(context, attrs, defStyleAttr, defStyleRes);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onAttachedToWindow() {
|
||||
super.onAttachedToWindow();
|
||||
handler.sendEmptyMessageDelayed(MSG_SEND_UPDATE, 1000L);
|
||||
CallerChassisGearStateListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerChassisBrakeStateListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerChassisThrottleStateListenerManager.INSTANCE.addListener(TAG, this);
|
||||
CallerPlanningActionsListenerManager.INSTANCE.addListener(TAG, this);
|
||||
}
|
||||
|
||||
private void initView(@NonNull Context context) {
|
||||
LayoutInflater.from(context).inflate(R.layout.shuttle_traffic_data, this);
|
||||
tapPositionView = findViewById(R.id.traffic_position);
|
||||
speedImage = findViewById(R.id.speedImage);
|
||||
speedTextView = findViewById(R.id.speedTextView);
|
||||
accTextView = findViewById(R.id.speedAccTextView);
|
||||
brakeStatus = findViewById(R.id.brakeStatus);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDetachedFromWindow() {
|
||||
super.onDetachedFromWindow();
|
||||
CallerChassisGearStateListenerManager.INSTANCE.removeListener(TAG);
|
||||
CallerChassisBrakeStateListenerManager.INSTANCE.removeListener(TAG);
|
||||
CallerChassisThrottleStateListenerManager.INSTANCE.removeListener(TAG);
|
||||
CallerPlanningActionsListenerManager.INSTANCE.removeListener(TAG);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void pncActions(@NonNull MessagePad.PlanningActionMsg planningActionMsg) {
|
||||
acceleration = planningActionMsg.getDestinationAcc();
|
||||
}
|
||||
|
||||
/**
|
||||
* 档位
|
||||
*/
|
||||
@Override
|
||||
public void onAutopilotGearData(@NotNull Chassis.GearPosition gear) {
|
||||
ThreadUtils.runOnUiThread(() -> {
|
||||
if (tapPositionView != null) {
|
||||
tapPositionView.updateWithGear(gear);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAutopilotBrake(float brake) {
|
||||
mBrake = brake;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAutopilotThrottle(float throttle) {
|
||||
mThrottle = throttle;
|
||||
}
|
||||
|
||||
/**
|
||||
* value呈现
|
||||
*/
|
||||
public void updateSpeedWithValue(int newSpeed) {
|
||||
if (speedTextView != null) {
|
||||
speedTextView.setText(String.valueOf(newSpeed));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 42 KiB |
@@ -3,7 +3,7 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:id="@+id/module_och_bus_order_status_stationInfo"
|
||||
android:layout_width="@dimen/module_mogo_och_autopilot_order_bg_width"
|
||||
android:layout_width="@dimen/dp_587"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="@dimen/dp_28"
|
||||
android:background="@drawable/bus_line_panel_bg"
|
||||
@@ -96,9 +96,10 @@
|
||||
|
||||
<TextView
|
||||
android:id="@+id/switch_line_btn"
|
||||
android:layout_width="@dimen/bus_switch_line_btn_width_1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/bus_switch_line_btn_height_1"
|
||||
android:layout_marginLeft="@dimen/dp_28"
|
||||
android:layout_marginStart="@dimen/dp_28"
|
||||
android:layout_marginEnd ="@dimen/dp_26"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
app:layout_goneMarginTop="@dimen/dp_550"
|
||||
android:background="@drawable/bus_switch_line_btn"
|
||||
|
||||
@@ -21,15 +21,15 @@
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_speed"
|
||||
android:layout_width="@dimen/dp_616"
|
||||
android:layout_height="@dimen/dp_320"
|
||||
android:layout_marginLeft="@dimen/dp_13"
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:layout_width="@dimen/dp_585"
|
||||
android:layout_height="@dimen/dp_304"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
android:layout_marginTop="@dimen/dp_5"
|
||||
android:visibility="visible"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.widget.TrafficDataView
|
||||
<com.mogo.och.bus.ui.ShuttleTrafficDataView
|
||||
android:id="@+id/bus_arc"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
@@ -163,9 +163,10 @@
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/module_mogo_och_autopilot_status"
|
||||
android:layout_width="@dimen/module_mogo_och_autopilot_status_bg_width"
|
||||
android:layout_height="@dimen/module_mogo_och_autopilot_status_bg_height"
|
||||
android:layout_marginLeft="@dimen/dp_13"
|
||||
android:layout_width="@dimen/dp_585"
|
||||
android:layout_height="@dimen/dp_171"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
android:layout_marginTop="@dimen/dp_m_10"
|
||||
android:background="@drawable/bus_autopilot_0_1_status_bg"
|
||||
android:gravity="center"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
@@ -197,7 +198,8 @@
|
||||
android:id="@+id/module_mogo_och_station_panel_container"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_13"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
android:layout_marginTop="@dimen/dp_m_10"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/module_mogo_och_autopilot_status"
|
||||
app:layout_goneMarginTop="@dimen/module_mogo_och_station_panel_container_margin_top_no_call" />
|
||||
@@ -211,15 +213,16 @@
|
||||
app:layout_constraintLeft_toLeftOf="@id/module_mogo_och_station_panel_container"
|
||||
app:layout_constraintTop_toBottomOf="@id/module_mogo_och_station_panel_container"
|
||||
tools:visibility="visible" />
|
||||
|
||||
|
||||
|
||||
<com.mogo.och.bus.ui.writeoff.WriteOffView
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintBottom_toTopOf="@+id/module_mogo_och_arrived_tv"
|
||||
android:layout_marginStart="@dimen/dp_12"
|
||||
android:layout_marginStart="@dimen/dp_15"
|
||||
android:layout_marginBottom="-40dp"
|
||||
android:background="@drawable/shuttle_write_off_bg"
|
||||
android:layout_width="@dimen/dp_618"
|
||||
android:layout_height="@dimen/dp_186"/>
|
||||
android:layout_width="@dimen/dp_585"
|
||||
android:layout_height="@dimen/dp_176"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/module_mogo_och_arrived_tv"
|
||||
@@ -0,0 +1,68 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tap_p"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="P"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/p_default_txt_color"
|
||||
android:textSize="@dimen/dp_34"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toLeftOf="@+id/tap_r"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tap_r"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="R"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/p_default_txt_color"
|
||||
android:textSize="@dimen/dp_34"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@+id/tap_p"
|
||||
app:layout_constraintRight_toLeftOf="@+id/tap_n"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tap_n"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="N"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/p_default_txt_color"
|
||||
android:textSize="@dimen/dp_34"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@+id/tap_r"
|
||||
app:layout_constraintRight_toLeftOf="@+id/tap_d"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tap_d"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="D"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/p_default_txt_color"
|
||||
android:textSize="@dimen/dp_34"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@+id/tap_n"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -0,0 +1,97 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="@dimen/dp_585"
|
||||
android:layout_height="@dimen/dp_304"
|
||||
android:background="@drawable/traffic_data_back">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/speedImage"
|
||||
android:layout_width="@dimen/dp_256"
|
||||
android:layout_height="@dimen/dp_256"
|
||||
android:layout_marginLeft="@dimen/dp_46"
|
||||
android:layout_marginTop="@dimen/dp_25"
|
||||
android:layout_marginBottom="@dimen/dp_25"
|
||||
android:background="@drawable/shuttle_traffic_data_speed"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/speedTextView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="80dp"
|
||||
android:text="0"
|
||||
android:textAlignment="center"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/dp_67"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/speedImage"
|
||||
app:layout_constraintRight_toRightOf="@+id/speedImage"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/kmTextView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_176"
|
||||
android:text="KM/H"
|
||||
android:textAlignment="center"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/dp_29"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/speedImage"
|
||||
app:layout_constraintRight_toRightOf="@+id/speedImage"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.ui.ShuttleTapPositionView
|
||||
android:id="@+id/traffic_position"
|
||||
android:layout_width="@dimen/dp_220"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_70"
|
||||
android:layout_marginRight="@dimen/dp_75"
|
||||
app:defaultColor="@color/acc_default_txt_color"
|
||||
app:layout_constraintLeft_toRightOf="@+id/speedImage"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:selectColor="@color/dark_mode_select_txt_color" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/brakeStatus"
|
||||
android:layout_width="@dimen/dp_64"
|
||||
android:layout_height="@dimen/dp_64"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginTop="@dimen/dp_164"
|
||||
android:layout_marginBottom="@dimen/dp_75"
|
||||
android:src="@drawable/traffic_data_empty"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toRightOf="@id/speedImage"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/speedAccTextView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_56"
|
||||
android:layout_marginEnd="@dimen/dp_80"
|
||||
android:gravity="end"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/dp_38"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/brakeStatus"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/brakeStatus"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_56"
|
||||
android:layout_marginLeft="@dimen/dp_14"
|
||||
android:text="a:"
|
||||
android:textAlignment="viewStart"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/dp_38"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/brakeStatus"
|
||||
app:layout_constraintLeft_toRightOf="@+id/brakeStatus"
|
||||
app:layout_constraintTop_toTopOf="@+id/brakeStatus"
|
||||
app:layout_goneMarginLeft="@dimen/dp_81" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -12,7 +12,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/shuttle_driver_cad6ff"
|
||||
android:textSize="32dp"
|
||||
android:textSize="30dp"
|
||||
android:layout_marginStart="@dimen/dp_68"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
|
||||
Reference in New Issue
Block a user