[3.2.0] bus/shuttle 乘客屏UI调整
This commit is contained in:
@@ -55,12 +55,12 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
if (position == 0){ //第一个 起点
|
||||
viewHolder.curArrowBg.setVisibility(View.GONE);
|
||||
if (station.getDrivingStatus() == STATION_STATUS_STOPPED && !station.isLeaving()){//到达未离开
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_current_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_17417B));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_arrive_line_green);
|
||||
BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||
}else {
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_992D3E5F));
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bg_bus_p_start_tag_bg);
|
||||
}
|
||||
@@ -69,7 +69,7 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
BusPassengerStation preStation = mStations.get(position -1);
|
||||
if (station.getDrivingStatus() == STATION_STATUS_LEAVING ||
|
||||
(station.getDrivingStatus() == STATION_STATUS_STOPPED && station.isLeaving())){ //过站
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_992D3E5F));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_A9B6CA));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_point_gray);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
@@ -80,14 +80,15 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||
}else if (station.getDrivingStatus() == STATION_STATUS_ARRIVING && preStation.isLeaving()){//即将到站
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_panel_cur_station_tips_color));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_A9B6CA));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_arrive_line_blue);
|
||||
|
||||
// BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
// viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||
}else if (station.getDrivingStatus() == STATION_STATUS_ARRIVING &&
|
||||
(preStation.getDrivingStatus() == STATION_STATUS_ARRIVING
|
||||
|| preStation.getDrivingStatus() == STATION_STATUS_STOPPED)){ //未到站的并且前面也是未到站或者刚到站的
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_panel_cur_station_tips_color));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_1F82FB));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_point_blue);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
@@ -95,7 +96,6 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
if (position == mStations.size() - 1){
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bg_bus_p_end_tag_bg);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,26 +1,42 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<com.mogo.och.common.module.wigets.OCHRoundConstraintLayout 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:padding="@dimen/dp_40"
|
||||
android:background="@android:color/transparent">
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:layout_marginRight="@dimen/dp_40"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
app:roundLayoutRadius="@dimen/dp_40">
|
||||
|
||||
<View
|
||||
android:layout_width="@dimen/bus_p_route_info_panel_width"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:background="@drawable/bus_p_route_bg"/>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="@dimen/bus_p_route_info_panel_width"
|
||||
android:layout_height="1120dp"
|
||||
android:background="@drawable/bus_p_route_bg"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toTopOf="@+id/busPLineMapView">
|
||||
|
||||
<View
|
||||
android:layout_width="@dimen/dp_698"
|
||||
android:layout_height="@dimen/dp_76"
|
||||
android:background="@drawable/route_line_name_bg"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent"/>
|
||||
|
||||
<com.mogo.och.common.module.wigets.MarqueeTextView
|
||||
android:id="@+id/bus_p_line_name_tv"
|
||||
android:layout_width="@dimen/dp_698"
|
||||
android:layout_width="@dimen/dp_340"
|
||||
android:layout_height="@dimen/dp_76"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="marquee"
|
||||
android:marqueeRepeatLimit="marquee_forever"
|
||||
android:background="@drawable/route_line_name_bg"
|
||||
android:text="@string/bus_p_no_line"
|
||||
android:gravity="center"
|
||||
app:customGap="0.5"
|
||||
@@ -40,7 +56,7 @@
|
||||
app:layout_constraintTop_toTopOf="@+id/bus_p_line_name_tv"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/bus_p_line_name_tv"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
android:layout_marginLeft="@dimen/dp_194"/>
|
||||
android:layout_marginLeft="@dimen/dp_160"/>
|
||||
|
||||
<com.mogo.och.common.module.wigets.OCHGradientTextView
|
||||
android:id="@+id/bus_p_speed_tv"
|
||||
@@ -275,4 +291,4 @@
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</com.mogo.och.common.module.wigets.OCHRoundConstraintLayout>
|
||||
@@ -10,12 +10,12 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:text="--"
|
||||
android:textSize="@dimen/bus_p_station_txt_size"
|
||||
android:textStyle="bold"
|
||||
android:includeFontPadding = "false"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="marquee"
|
||||
android:marqueeRepeatLimit="marquee_forever"
|
||||
android:layout_marginRight="@dimen/dp_60"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/bus_p_station_txt_color"
|
||||
android:layout_marginLeft="@dimen/dp_90"
|
||||
app:customGap="0.5"
|
||||
@@ -34,8 +34,8 @@
|
||||
app:layout_constraintBottom_toBottomOf="@+id/bus_p_station"/>
|
||||
<ImageView
|
||||
android:id="@+id/bus_p_cur_arrow_bg"
|
||||
android:layout_width="@dimen/dp_12"
|
||||
android:layout_height="@dimen/dp_88"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_68"
|
||||
android:scaleType="fitXY"
|
||||
android:background="@color/acc_default_txt_color"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/bus_p_circle"
|
||||
|
||||
@@ -35,4 +35,7 @@
|
||||
<color name="bus_p_clock_6617417B">#6617417B</color>
|
||||
<color name="bus_p_clock_A9B6CA">#A9B6CA</color>
|
||||
<color name="bus_p_clock_1F82FB">#1F82FB</color>
|
||||
|
||||
<color name="bus_p_clock_992D3E5F">#992D3E5F</color>
|
||||
|
||||
</resources>
|
||||
@@ -54,12 +54,12 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
if (position == 0){ //第一个 起点
|
||||
viewHolder.curArrowBg.setVisibility(View.GONE);
|
||||
if (station.getDrivingStatus() == STATION_STATUS_STOPPED && !station.isLeaving()){//到达未离开
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_current_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_17417B));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_arrive_line_green);
|
||||
BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||
}else {
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_992D3E5F));
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bg_bus_p_start_tag_bg);
|
||||
}
|
||||
@@ -68,7 +68,7 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
BusStationBean preStation = mStations.get(position -1);
|
||||
if (station.getDrivingStatus() == STATION_STATUS_LEAVING ||
|
||||
(station.getDrivingStatus() == STATION_STATUS_STOPPED && station.isLeaving())){ //过站
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_clock_992D3E5F));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_A9B6CA));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_point_gray);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
@@ -79,7 +79,7 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.MARQUEE);
|
||||
}else if (station.getDrivingStatus() == STATION_STATUS_ARRIVING && preStation.isLeaving()){//即将到站
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_panel_cur_station_tips_color));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_A9B6CA));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_arrive_line_blue);
|
||||
// BlinkAnimationUtil.setAnimation(viewHolder.stationCircle);
|
||||
@@ -87,7 +87,7 @@ public class BusPassengerLineStationsAdapter extends RecyclerView.Adapter<Recycl
|
||||
}else if (station.getDrivingStatus() == STATION_STATUS_ARRIVING &&
|
||||
(preStation.getDrivingStatus() == STATION_STATUS_ARRIVING
|
||||
|| preStation.getDrivingStatus() == STATION_STATUS_STOPPED)){ //未到站的并且前面也是未到站或者刚到站的
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_station_txt_color));
|
||||
viewHolder.stationName.setTextColor(mContext.getResources().getColor(R.color.bus_p_panel_cur_station_tips_color));
|
||||
viewHolder.curArrowBg.setBackgroundColor(mContext.getColor(R.color.bus_p_clock_1F82FB));
|
||||
viewHolder.stationCircle.setImageResource(R.drawable.bus_p_point_blue);
|
||||
viewHolder.stationName.setEllipsize(TextUtils.TruncateAt.END);
|
||||
|
||||
@@ -1,17 +1,26 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<com.mogo.och.common.module.wigets.OCHRoundConstraintLayout 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:padding="@dimen/dp_40"
|
||||
android:background="@android:color/transparent">
|
||||
android:layout_marginTop="@dimen/dp_40"
|
||||
android:layout_marginRight="@dimen/dp_40"
|
||||
android:layout_marginBottom="@dimen/dp_40"
|
||||
app:roundLayoutRadius="@dimen/dp_40">
|
||||
|
||||
<View
|
||||
android:layout_width="@dimen/bus_p_route_info_panel_width"
|
||||
android:layout_height="match_parent"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
android:background="@drawable/bus_p_route_bg"/>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="@dimen/bus_p_route_info_panel_width"
|
||||
android:layout_height="1120dp"
|
||||
android:background="@drawable/bus_p_route_bg"
|
||||
android:layout_height="0dp"
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent">
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toTopOf="@+id/bus_p_line_map_view">
|
||||
|
||||
<com.mogo.och.common.module.wigets.MarqueeTextView
|
||||
android:id="@+id/bus_p_line_name_tv"
|
||||
@@ -241,16 +250,4 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
<!-- <ImageView-->
|
||||
<!-- android:id="@+id/bus_p_arrow_nor"-->
|
||||
<!-- android:layout_width="@dimen/dp_108"-->
|
||||
<!-- android:layout_height="@dimen/dp_107"-->
|
||||
<!-- android:layout_marginRight="@dimen/dp_20"-->
|
||||
<!-- android:layout_marginBottom="@dimen/dp_370"-->
|
||||
<!-- android:src="@drawable/bus_p_arrow_nor"-->
|
||||
<!-- app:layout_constraintBottom_toBottomOf="parent"-->
|
||||
<!-- app:layout_constraintRight_toRightOf="parent" />-->
|
||||
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</com.mogo.och.common.module.wigets.OCHRoundConstraintLayout>
|
||||
@@ -10,12 +10,12 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:text="--"
|
||||
android:textSize="@dimen/bus_p_station_txt_size"
|
||||
android:textStyle="bold"
|
||||
android:includeFontPadding = "false"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="marquee"
|
||||
android:marqueeRepeatLimit="marquee_forever"
|
||||
android:layout_marginRight="@dimen/dp_60"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/bus_p_station_txt_color"
|
||||
android:layout_marginLeft="@dimen/dp_90"
|
||||
app:customGap="0.5"
|
||||
@@ -34,8 +34,8 @@
|
||||
app:layout_constraintBottom_toBottomOf="@+id/bus_p_station"/>
|
||||
<ImageView
|
||||
android:id="@+id/bus_p_cur_arrow_bg"
|
||||
android:layout_width="@dimen/dp_12"
|
||||
android:layout_height="@dimen/dp_88"
|
||||
android:layout_width="@dimen/dp_10"
|
||||
android:layout_height="@dimen/dp_68"
|
||||
android:scaleType="fitXY"
|
||||
android:background="@color/acc_default_txt_color"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/bus_p_circle"
|
||||
|
||||
@@ -35,4 +35,7 @@
|
||||
<color name="bus_p_clock_6617417B">#6617417B</color>
|
||||
<color name="bus_p_clock_A9B6CA">#A9B6CA</color>
|
||||
<color name="bus_p_clock_1F82FB">#1F82FB</color>
|
||||
|
||||
<color name="bus_p_clock_992D3E5F">#992D3E5F</color>
|
||||
|
||||
</resources>
|
||||
Reference in New Issue
Block a user