Files
VscoolOS/app/src/main/res/layout/fragment_home.xml
Fanhuitong a187a9e84e version:3.7
fix:
update:修改主页
2023-10-16 09:13:41 +08:00

306 lines
15 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".fragment.home.HomeFragment">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="@dimen/dp_527"
android:layout_height="@dimen/dp_309"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_weather"
android:layout_width="@dimen/dp_157"
android:layout_height="@dimen/dp_96"
android:background="@drawable/home_weather_calendar"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<TextView
android:id="@+id/tv_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dp_4"
android:layout_marginTop="@dimen/dp_4"
android:maxLines="1"
android:textColor="@color/white"
android:textSize="@dimen/sp_18"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:text="00:00" />
<ImageView
android:layout_width="@dimen/dp_10"
android:layout_marginEnd="@dimen/dp_2"
android:layout_height="@dimen/dp_10"
android:src="@drawable/home_icon_location"
app:layout_constraintBottom_toBottomOf="@+id/tv_location"
app:layout_constraintEnd_toStartOf="@+id/tv_location"
app:layout_constraintTop_toTopOf="@+id/tv_location" />
<TextView
android:id="@+id/tv_location"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_4"
android:layout_marginEnd="@dimen/dp_4"
android:text="位置"
android:textColor="@color/white"
android:textSize="@dimen/sp_8"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/tv_data"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_4"
android:maxLines="1"
android:textColor="@color/white"
android:textSize="@dimen/sp_8"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="@+id/tv_time"
app:layout_constraintTop_toBottomOf="@+id/tv_time"
tools:text="20230621" />
<ImageView
android:id="@+id/iv_pic"
android:layout_width="@dimen/dp_40"
android:layout_height="@dimen/dp_40"
android:adjustViewBounds="true"
android:scaleType="fitCenter"
android:src="@drawable/he100"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="@+id/tv_data"
app:layout_constraintTop_toBottomOf="@+id/tv_data" />
<TextView
android:id="@+id/tv_temp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dp_8"
android:gravity="center_vertical"
android:text="10℃"
android:textColor="@color/white"
android:textSize="@dimen/sp_16"
app:layout_constraintStart_toEndOf="@+id/iv_pic"
app:layout_constraintTop_toTopOf="@+id/iv_pic" />
<TextView
android:id="@+id/tv_weather"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="@dimen/dp_8"
android:text="天气"
android:textColor="@color/white"
android:textSize="@dimen/sp_8"
app:layout_constraintBottom_toBottomOf="@+id/iv_pic"
app:layout_constraintStart_toEndOf="@+id/iv_pic"
app:layout_constraintTop_toBottomOf="@+id/tv_temp" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_app"
android:layout_width="@dimen/dp_157"
android:layout_height="@dimen/dp_203"
android:layout_marginTop="@dimen/dp_10"
android:background="@drawable/home_daily_app"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/cl_weather">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/rv_app"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginTop="@dimen/dp_24"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/iv_nodata"
android:layout_width="@dimen/dp_64"
android:layout_height="@dimen/dp_64"
android:adjustViewBounds="true"
android:scaleType="centerCrop"
android:src="@drawable/nodata"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/rv_app" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_space"
android:layout_width="@dimen/dp_115"
android:layout_height="@dimen/dp_142"
android:layout_marginStart="@dimen/dp_13"
android:background="@drawable/home_family_space"
app:layout_constraintStart_toEndOf="@+id/cl_weather"
app:layout_constraintTop_toTopOf="parent">
<ImageView
android:layout_width="@dimen/dp_69"
android:layout_height="@dimen/dp_90"
android:src="@drawable/home_icon_space"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_health"
android:layout_width="@dimen/dp_115"
android:layout_height="@dimen/dp_154"
android:background="@drawable/home_health_protection"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="@+id/cl_space">
<com.shehuan.niv.NiceImageView
android:layout_width="@dimen/dp_24"
android:layout_height="@dimen/dp_24"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginEnd="@dimen/dp_8"
android:src="@drawable/home_avatar_icon"
app:is_circle="true"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/imageView10"
android:layout_width="@dimen/dp_31"
android:layout_height="@dimen/dp_53"
android:src="@drawable/home_add_hardware"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp_4"
android:text="添加硬件"
android:textColor="#38333C"
android:textSize="@dimen/sp_8"
app:layout_constraintEnd_toEndOf="@+id/imageView10"
app:layout_constraintStart_toStartOf="@+id/imageView10"
app:layout_constraintTop_toBottomOf="@+id/imageView10" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_alarmclock"
android:layout_width="@dimen/dp_230"
android:layout_height="@dimen/dp_142"
android:layout_marginStart="@dimen/dp_12"
android:background="@drawable/home_love_reminder"
app:layout_constraintStart_toEndOf="@+id/cl_space"
app:layout_constraintTop_toTopOf="parent">
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/rv_noti"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginTop="@dimen/dp_24"
android:overScrollMode="never"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/iv_note_nodata"
android:layout_width="@dimen/dp_68"
android:layout_height="@dimen/dp_68"
android:adjustViewBounds="true"
android:scaleType="centerInside"
android:src="@drawable/home_reminder_icon"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/constraintLayout19"
android:layout_width="@dimen/dp_230"
android:layout_height="@dimen/dp_154"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="@+id/cl_alarmclock">
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_clear"
android:layout_width="@dimen/dp_109"
android:layout_height="@dimen/dp_71"
android:background="@drawable/home_app_acceleration"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<com.king.view.circleprogressview.CircleProgressView
android:id="@+id/cpv"
android:layout_width="@dimen/dp_56"
android:layout_height="@dimen/dp_56"
app:cpvDuration="1000"
app:cpvLabelTextColor="#02B1AF"
app:cpvLabelTextSize="@dimen/sp_11"
app:cpvNormalColor="#2F7775"
app:cpvProgressColor="#02B1AF"
app:cpvShowTick="false"
app:cpvStrokeWidth="@dimen/dp_6"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_sos"
android:layout_width="@dimen/dp_109"
android:layout_height="@dimen/dp_71"
android:layout_marginStart="@dimen/dp_13"
android:background="@drawable/home_emergency_call"
app:layout_constraintStart_toEndOf="@+id/cl_clear"
app:layout_constraintTop_toTopOf="parent">
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_contact"
android:layout_width="@dimen/dp_109"
android:layout_height="@dimen/dp_71"
android:layout_marginTop="@dimen/dp_13"
android:background="@drawable/home_dialer"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/cl_clear">
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/cl_appstore"
android:layout_width="@dimen/dp_109"
android:layout_height="@dimen/dp_71"
android:background="@drawable/home_application_icon"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="@+id/cl_sos"
app:layout_constraintTop_toTopOf="@+id/cl_contact" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.constraintlayout.widget.ConstraintLayout>
</FrameLayout>