From 1097c45d8d6aa4b74a50e8d9a99dedab73f2bbad Mon Sep 17 00:00:00 2001 From: cloudroam <cloudroam> Date: 星期五, 28 二月 2025 13:35:07 +0800 Subject: [PATCH] add: 优化首页自动同步历史短信,和实时刷新包裹列表 --- app/src/main/res/layout/fragment_reminder_settings.xml | 206 +++++++++++++++++++++++++++++++++------------------ 1 files changed, 132 insertions(+), 74 deletions(-) diff --git a/app/src/main/res/layout/fragment_reminder_settings.xml b/app/src/main/res/layout/fragment_reminder_settings.xml index 8403cd9..57988dd 100644 --- a/app/src/main/res/layout/fragment_reminder_settings.xml +++ b/app/src/main/res/layout/fragment_reminder_settings.xml @@ -2,87 +2,145 @@ <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" - android:orientation="vertical"> + android:orientation="vertical" + android:background="#FAFAFA"> <!-- 标题栏 --> - <RelativeLayout - android:layout_width="match_parent" - android:layout_height="?attr/actionBarSize" - android:background="#FFFFFF"> +<!-- <RelativeLayout--> +<!-- android:layout_width="match_parent"--> +<!-- android:layout_height="56dp"--> +<!-- android:background="#FFFFFF"--> +<!-- android:elevation="1dp">--> +<!-- <TextView--> +<!-- android:layout_width="wrap_content"--> +<!-- android:layout_height="wrap_content"--> +<!-- android:layout_centerInParent="true"--> +<!-- android:text="新增短信提醒"--> +<!-- android:textSize="17sp"--> +<!-- android:textColor="#222222" />--> + +<!-- <!– 关闭按钮 –>--> +<!-- <ImageButton--> +<!-- android:id="@+id/btn_close"--> +<!-- android:layout_width="48dp"--> +<!-- android:layout_height="48dp"--> +<!-- android:layout_alignParentEnd="true"--> +<!-- android:layout_centerVertical="true"--> +<!-- android:background="?attr/selectableItemBackgroundBorderless"--> +<!-- android:padding="12dp"--> +<!-- android:src="@android:drawable/ic_menu_close_clear_cancel" />--> +<!-- </RelativeLayout>--> + + <!-- 内容区域 --> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:padding="16dp"> + + <!-- 提醒类型选择 --> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:layout_marginBottom="16dp"> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="选择新增类型 →" + android:textColor="#666666" + android:textSize="14sp" + android:layout_marginBottom="8dp"/> + + <Spinner + android:id="@+id/spinner_type" + android:layout_width="match_parent" + android:layout_height="48dp" + android:background="@drawable/bg_edit_border" + android:paddingHorizontal="12dp"/> + </LinearLayout> + + <!-- 昵称输入框 --> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:layout_marginBottom="16dp"> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="昵称 →" + android:textColor="#666666" + android:textSize="14sp" + android:layout_marginBottom="8dp"/> + + <EditText + android:id="@+id/edit_nickname" + android:layout_width="match_parent" + android:layout_height="48dp" + android:background="@drawable/bg_edit_border" + android:hint="仅用于显示与区分,可任意输入" + android:textColorHint="#999999" + android:textSize="14sp" + android:paddingHorizontal="12dp"/> + </LinearLayout> + + <!-- 关键词输入框 --> + <LinearLayout + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:orientation="vertical" + android:layout_marginBottom="16dp"> + + <TextView + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:text="关键词 →" + android:textColor="#666666" + android:textSize="14sp" + android:layout_marginBottom="8dp"/> + + <EditText + android:id="@+id/edit_keywords" + android:layout_width="match_parent" + android:layout_height="48dp" + android:background="@drawable/bg_edit_border" + android:hint="用于匹配短信类型" + android:textColorHint="#999999" + android:textSize="14sp" + android:paddingHorizontal="12dp"/> + </LinearLayout> + + <!-- 确定新增按钮 --> + <Button + android:id="@+id/btn_add_reminder" + android:layout_width="match_parent" + android:layout_height="48dp" + android:text="确定新增" + android:textColor="#FFFFFF" + android:textSize="16sp" + android:background="@drawable/bg_button_primary" + android:layout_marginTop="16dp"/> + + <!-- 已添加列表 --> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_centerInParent="true" - android:text="新增短信提醒" - android:textSize="18sp" - android:textColor="#000000" /> + android:text="已添加列表 →" + android:textColor="#666666" + android:textSize="14sp" + android:layout_marginTop="24dp" + android:layout_marginBottom="8dp"/> - <!-- 关闭按钮 --> - <ImageButton - android:id="@+id/btn_close" - android:layout_width="48dp" - android:layout_height="48dp" - android:layout_alignParentEnd="true" - android:layout_centerVertical="true" - android:background="?attr/selectableItemBackgroundBorderless" - android:src="@android:drawable/ic_menu_close_clear_cancel" /> - </RelativeLayout> + <androidx.recyclerview.widget.RecyclerView + android:id="@+id/recycler_reminders" + android:layout_width="match_parent" + android:layout_height="160dp" + android:layout_marginTop="2dp" /> - <!-- 提醒类型选择 --> - <Spinner - android:id="@+id/spinner_type" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_margin="16dp" - android:padding="12dp" - android:background="@android:drawable/btn_dropdown" /> - - <!-- 昵称输入框 --> - <EditText - android:id="@+id/edit_nickname" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginHorizontal="16dp" - android:hint="昵称" - android:padding="12dp" - android:background="@android:drawable/edit_text" /> - - <!-- 关键词输入框 --> - <EditText - android:id="@+id/edit_keywords" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_margin="16dp" - android:hint="关键词" - android:padding="12dp" - android:background="@android:drawable/edit_text" /> - - <!-- 已添加列表标题 --> - <Button - android:id="@+id/btn_add_reminder" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_margin="16dp" - android:backgroundTint="#03A9F4" - android:text="确定新增" - android:textColor="#FFFFFF" /> - - <TextView - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:padding="16dp" - android:text="已添加列表" - android:textStyle="bold" /> - - <!-- 已添加列表 --> - <androidx.recyclerview.widget.RecyclerView - android:id="@+id/recycler_reminders" - android:layout_width="match_parent" - android:layout_height="221dp" - android:layout_weight="1" - android:padding="8dp" /> - - <!-- 确定新增按钮 --> + </LinearLayout> </LinearLayout> \ No newline at end of file -- Gitblit v1.9.3