From: TrillGates Date: Wed, 30 Jun 2021 02:22:44 +0000 (+0800) Subject: adjust sport record UI X-Git-Url: http://git.snicker.com.cn/Users/apple/Desktop/static/gitweb.css?a=commitdiff_plain;h=a5b95bc8e094f7f00d4eafec0537f671203e0374;p=ichardware.git adjust sport record UI --- diff --git a/app/src/main/java/com/ic/sport/adapter/PedRecordAdapter.java b/app/src/main/java/com/ic/sport/adapter/PedRecordAdapter.java index c48ce5b..a5d7df7 100644 --- a/app/src/main/java/com/ic/sport/adapter/PedRecordAdapter.java +++ b/app/src/main/java/com/ic/sport/adapter/PedRecordAdapter.java @@ -20,12 +20,12 @@ public class PedRecordAdapter extends RecyclerView.Adapter mPedRecord; - public PedRecordAdapter(Context context){ + public PedRecordAdapter(Context context) { this.mContext = context; this.mPedRecord = new ArrayList<>(); } - public void updatePedRecordList(List records){ + public void updatePedRecordList(List records) { mPedRecord.clear(); mPedRecord.addAll(records); notifyDataSetChanged(); @@ -34,12 +34,14 @@ public class PedRecordAdapter extends RecyclerView.Adapter + + + + + + android:layout_height="match_parent" + android:layout_marginTop="40dp" + android:layout_marginBottom="20dp" /> \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_ped_main.xml b/app/src/main/res/layout/fragment_ped_main.xml index bd91734..5e86a64 100644 --- a/app/src/main/res/layout/fragment_ped_main.xml +++ b/app/src/main/res/layout/fragment_ped_main.xml @@ -14,11 +14,9 @@ type="String" /> - + android:layout_height="match_parent"> + android:textSize="42sp" /> - + android:layout_above="@id/ped_number_tv" + android:layout_centerHorizontal="true" + android:layout_marginBottom="-10dp" + android:src="@mipmap/icon_step_white" /> - + + \ No newline at end of file diff --git a/app/src/main/res/layout/fragment_ped_record.xml b/app/src/main/res/layout/fragment_ped_record.xml index 34df0d6..7a29d49 100644 --- a/app/src/main/res/layout/fragment_ped_record.xml +++ b/app/src/main/res/layout/fragment_ped_record.xml @@ -1,25 +1,12 @@ - - - + android:layout_height="match_parent"> - \ No newline at end of file + android:layout_height="match_parent" /> + + \ No newline at end of file diff --git a/app/src/main/res/layout/item_ped_record.xml b/app/src/main/res/layout/item_ped_record.xml index a693a73..9cdbe62 100644 --- a/app/src/main/res/layout/item_ped_record.xml +++ b/app/src/main/res/layout/item_ped_record.xml @@ -59,22 +59,19 @@ - + app:cardBackgroundColor="#1D1D1D" + app:cardCornerRadius="50dp"> @@ -82,7 +79,9 @@ android:id="@+id/item_record_taking" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginLeft="30dp" + android:layout_alignParentBottom="true" + android:layout_marginLeft="10dp" + android:layout_marginBottom="5dp" icApp:widgetImageColor="@{takingColor}" icApp:widgetImageIcon="@{takingIcon}" icApp:widgetImageUnit="@{takingUnit}" @@ -92,7 +91,9 @@ android:id="@+id/item_record_calories" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginLeft="30dp" + android:layout_alignParentRight="true" + android:layout_marginTop="5dp" + android:layout_marginRight="10dp" icApp:widgetImageColor="@{caloriesColor}" icApp:widgetImageIcon="@{caloriesIcon}" icApp:widgetImageUnit="@{caloriesUnit}" @@ -103,11 +104,14 @@ android:id="@+id/item_record_distance" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginLeft="30dp" + android:layout_alignParentRight="true" + android:layout_alignParentBottom="true" + android:layout_marginRight="10dp" + android:layout_marginBottom="5dp" icApp:widgetImageColor="@{distanceColor}" icApp:widgetImageIcon="@{distanceIcon}" icApp:widgetImageUnit="@{distanceUnit}" icApp:widgetImageValue="@{recordDistance}" /> - + diff --git a/app/src/main/res/mipmap-mdpi/icon_arrow.png b/app/src/main/res/mipmap-mdpi/icon_arrow.png new file mode 100644 index 0000000..e345e97 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_arrow.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_calorie_big.png b/app/src/main/res/mipmap-mdpi/icon_calorie_big.png new file mode 100644 index 0000000..487561e Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_calorie_big.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_calorie_small.png b/app/src/main/res/mipmap-mdpi/icon_calorie_small.png new file mode 100644 index 0000000..b7dc16c Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_calorie_small.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_height.png b/app/src/main/res/mipmap-mdpi/icon_height.png new file mode 100644 index 0000000..e131462 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_height.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_line.png b/app/src/main/res/mipmap-mdpi/icon_line.png new file mode 100644 index 0000000..a1e01e8 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_line.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_step_green.png b/app/src/main/res/mipmap-mdpi/icon_step_green.png new file mode 100644 index 0000000..48f7883 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_step_green.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_step_white.png b/app/src/main/res/mipmap-mdpi/icon_step_white.png new file mode 100644 index 0000000..c966aae Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_step_white.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_target.png b/app/src/main/res/mipmap-mdpi/icon_target.png new file mode 100644 index 0000000..ff599f0 Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_target.png differ diff --git a/app/src/main/res/mipmap-mdpi/icon_weight.png b/app/src/main/res/mipmap-mdpi/icon_weight.png new file mode 100644 index 0000000..5f8ea8d Binary files /dev/null and b/app/src/main/res/mipmap-mdpi/icon_weight.png differ diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index 7ddcf69..535a4e2 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -8,7 +8,7 @@ #20000000 - #FFCECBCB + #111B01 #f6f6f6 @@ -27,7 +27,7 @@ #DDDDDD #2DDB97 #FF20D18C - #34e8a6 + #A0FE1E #22ddb0 #E6F9F7 #50000000 diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml index fea0f48..8a45a43 100644 --- a/app/src/main/res/values/styles.xml +++ b/app/src/main/res/values/styles.xml @@ -6,15 +6,15 @@ @color/colorPrimary @color/colorPrimaryDark @color/colorAccent - true - @android:color/transparent + @android:color/black