修改f/m 导航 周边事件 目的车友UI

This commit is contained in:
zhuangyan
2020-11-19 17:13:09 +08:00
parent 3019fcd7e4
commit 6a65e87be0
35 changed files with 123 additions and 56 deletions

View File

@@ -209,11 +209,13 @@ public class V2XSurroundingFragment extends MvpFragment<SurroundingEventView, Su
//总条数
String originStr = String.format(getContext().getResources().getString(R.string.v2x_surrounding_top_brief), exploreWayList.size());
SpannableString spannableString = new SpannableString(originStr);
spannableString.setSpan(new ForegroundColorSpan(Color.parseColor("#459DFF")), 7, originStr.length() - 5, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
spannableString.setSpan(new ForegroundColorSpan(Color.parseColor("#459DFF")),
7, originStr.length() - 5, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
//设置字体大小true表示前面的字体大小 dip
spannableString.setSpan(new AbsoluteSizeSpan((int) getContext().getResources().getDimension(R.dimen.module_v2x_surrounding_top), true),
7, originStr.length() - 5, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
spannableString.setSpan(new StyleSpan(Typeface.NORMAL), 7, originStr.length() - 5, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
spannableString.setSpan(new StyleSpan(Typeface.BOLD), 7,
originStr.length() - 5, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
mTotalTv.setText(spannableString);
} else {
mTopLayout.setVisibility(View.GONE);

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/v2x_panel_close_press" android:state_pressed="true" />
<item android:drawable="@drawable/v2x_panel_close" android:state_pressed="false" />
<item android:drawable="@drawable/v2x_panel_close" />
</selector>

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/v2x_panel_close_press_light" android:state_pressed="true" />
<item android:drawable="@drawable/v2x_panel_close_light" android:state_pressed="false" />
<item android:drawable="@drawable/v2x_panel_close_light" />
</selector>

View File

@@ -28,23 +28,32 @@
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:layout_marginLeft="@dimen/module_v2x_surrounding_margin_left"
android:gravity="center_vertical"
android:text="周围5公里共15条交通信息"
android:textColor="@color/v2x_white"
android:textSize="@dimen/module_v2x_surrounding_top_textsize" />
<!-- android:layout_centerInParent="true"-->
<TextView
android:id="@+id/tv_top_refresh"
<RelativeLayout
android:layout_width="@dimen/module_v2x_surrounding_top_bt_width"
android:layout_height="@dimen/module_v2x_surrounding_top_bt_height"
android:layout_alignParentRight="true"
android:layout_alignParentBottom="true"
android:layout_marginRight="@dimen/module_v2x_surrounding_margin_left"
android:layout_centerVertical="true"
android:layout_marginEnd="@dimen/module_v2x_surrounding_margin_left"
android:background="@drawable/bg_v2x_refresh"
android:gravity="center"
android:text="@string/v2x_surrounding_refresh"
android:textColor="@color/v2x_item_white"
android:textSize="@dimen/module_v2x_surrounding_top_textsize"
android:textStyle="bold" />
android:gravity="center">
<TextView
android:id="@+id/tv_top_refresh"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_centerInParent="true"
android:gravity="center|center_horizontal"
android:text="@string/v2x_surrounding_refresh"
android:textColor="@color/v2x_item_white"
android:textSize="@dimen/module_v2x_surrounding_top_textsize"
android:textStyle="bold" />
</RelativeLayout>
</RelativeLayout>
<!--列表相关-->
@@ -146,9 +155,9 @@
<!--周边详情-->
<RelativeLayout
android:id="@+id/layout_surrounding_event_detail"
android:visibility="gone"
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:visibility="gone">
<!--顶部layout-->
<RelativeLayout
@@ -158,20 +167,20 @@
<ImageView
android:id="@+id/back_image"
android:layout_alignParentTop="true"
android:src="@drawable/icon_report_err"
android:layout_marginLeft="@dimen/module_v2x_surrounding_margin_left"
android:layout_centerVertical="true"
android:layout_width="25px"
android:layout_height="25px"/>
android:layout_height="25px"
android:layout_alignParentTop="true"
android:layout_centerVertical="true"
android:layout_marginLeft="@dimen/module_v2x_surrounding_margin_left"
android:src="@drawable/icon_report_err" />
<TextView
android:id="@+id/tv_brief_detail"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_alignParentTop="true"
android:layout_toRightOf="@+id/back_image"
android:layout_marginLeft="10px"
android:layout_toRightOf="@+id/back_image"
android:text="周围5公里共15条交通信息"
android:textColor="@color/v2x_white"
android:textSize="@dimen/module_v2x_surrounding_top_textsize" />
@@ -180,9 +189,9 @@
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/surrounding_detail_recycleview"
android:layout_marginTop="30dp"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="30dp"
android:visibility="visible" />
</RelativeLayout>

View File

@@ -87,7 +87,7 @@
android:layout_width="@dimen/dp_79"
android:layout_height="@dimen/dp_79"
android:layout_marginRight="@dimen/dp_50"
android:background="@drawable/v2x_panel_close"
android:background="@drawable/v2x_selector_colse"
app:layout_constraintBottom_toBottomOf="@+id/rgTabSelect"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="@+id/rgTabSelect" />

View File

@@ -43,7 +43,7 @@
<dimen name="module_v2x_surrounding_item_marigin_bottom_left">8px</dimen>
<dimen name="module_v2x_panel_surrounding_marginbottom">2px</dimen>
<dimen name="module_v2x_panel_surrounding_stance">30px</dimen>
<dimen name="module_v2x_surrounding_top">34px</dimen>
<dimen name="module_v2x_surrounding_top">22px</dimen>
<dimen name="module_v2x_surrounding_list_margin_left">12px</dimen>
<dimen name="module_v2x_surrounding_item_margin_left">16px</dimen>

View File

@@ -44,7 +44,7 @@
<dimen name="module_v2x_surrounding_item_marigin_bottom_left">8px</dimen>
<dimen name="module_v2x_panel_surrounding_marginbottom">2px</dimen>
<dimen name="module_v2x_panel_surrounding_stance">30px</dimen>
<dimen name="module_v2x_surrounding_top">34px</dimen>
<dimen name="module_v2x_surrounding_top">22px</dimen>
<dimen name="module_v2x_surrounding_list_margin_left">12px</dimen>
<dimen name="module_v2x_surrounding_item_margin_left">16px</dimen>

View File

@@ -41,13 +41,13 @@
<dimen name="module_v2x_surrounding_item_marigin_bottom_left">16px</dimen>
<dimen name="module_v2x_panel_surrounding_marginbottom">5px</dimen>
<dimen name="module_v2x_panel_surrounding_stance">80px</dimen>
<dimen name="module_v2x_surrounding_top">33px</dimen>
<dimen name="module_v2x_surrounding_top">22px</dimen>
<dimen name="module_v2x_surrounding_list_margin_left">20px</dimen>
<dimen name="module_v2x_surrounding_item_margin_left">30px</dimen>
<dimen name="module_v2x_surrounding_refresh_bt_radius">42px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">32px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">30px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_left_textsize">36px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_right_textsize">30px</dimen>
<dimen name="module_v2x_surrounding_item_maigin_left">50px</dimen>

View File

@@ -23,8 +23,8 @@
<dimen name="module_v2x_map_right">200px</dimen>
<dimen name="module_v2x_map_bottom">100px</dimen>
<dimen name="module_v2x_surrounding_top_height">90px</dimen>
<dimen name="module_v2x_surrounding_top_bt_width">162px</dimen>
<dimen name="module_v2x_surrounding_top_bt_height">64px</dimen>
<dimen name="module_v2x_surrounding_top_bt_width">168px</dimen>
<dimen name="module_v2x_surrounding_top_bt_height">68px</dimen>
<dimen name="module_v2x_surrounding_empty_iv_margin_top">80px</dimen>
<dimen name="module_v2x_surrounding_empty_tv_margin_top">26px</dimen>
<dimen name="module_v2x_surrounding_empty_bt_width">270px</dimen>
@@ -41,13 +41,13 @@
<dimen name="module_v2x_surrounding_item_marigin_bottom_left">16px</dimen>
<dimen name="module_v2x_panel_surrounding_marginbottom">5px</dimen>
<dimen name="module_v2x_panel_surrounding_stance">80px</dimen>
<dimen name="module_v2x_surrounding_top">33px</dimen>
<dimen name="module_v2x_surrounding_top">22px</dimen>
<dimen name="module_v2x_surrounding_list_margin_left">20px</dimen>
<dimen name="module_v2x_surrounding_item_margin_left">30px</dimen>
<dimen name="module_v2x_surrounding_refresh_bt_radius">42px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">32px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">30px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_left_textsize">36px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_right_textsize">30px</dimen>
<dimen name="module_v2x_surrounding_item_maigin_left">50px</dimen>

View File

@@ -24,8 +24,8 @@
<dimen name="module_v2x_map_right">200px</dimen>
<dimen name="module_v2x_map_bottom">100px</dimen>
<dimen name="module_v2x_surrounding_top_height">50px</dimen>
<dimen name="module_v2x_surrounding_top_bt_width">90px</dimen>
<dimen name="module_v2x_surrounding_top_bt_height">36px</dimen>
<dimen name="module_v2x_surrounding_top_bt_width">168px</dimen>
<dimen name="module_v2x_surrounding_top_bt_height">68px</dimen>
<dimen name="module_v2x_surrounding_empty_iv_margin_top">40px</dimen>
<dimen name="module_v2x_surrounding_empty_tv_margin_top">15px</dimen>
<dimen name="module_v2x_surrounding_empty_bt_width">150px</dimen>
@@ -41,14 +41,15 @@
<dimen name="module_v2x_surrounding_item_marigin_bottom_left">8px</dimen>
<dimen name="module_v2x_panel_surrounding_marginbottom">2px</dimen>
<dimen name="module_v2x_panel_surrounding_stance">30px</dimen>
<dimen name="module_v2x_surrounding_top">50px</dimen>
<dimen name="module_v2x_surrounding_top">22px</dimen>
<dimen name="module_v2x_surrounding_refresh_bt_radius">24px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">18px</dimen>
<dimen name="module_v2x_surrounding_top_textsize">30px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_left_textsize">20px</dimen>
<dimen name="module_v2x_surrounding_item_bottom_right_textsize">16px</dimen>
<dimen name="module_v2x_surrounding_item_maigin_left">28px</dimen>
<dimen name="module_v2x_panel_width">82px</dimen>
<dimen name="module_v2x_panel_icon_cor">16px</dimen>
<dimen name="share_empty_icon_width">117px</dimen>