Files
babelive_and/app/src/main/res/layout-large/fragment_home.xml
2026-02-06 14:55:21 +08:00

155 lines
6.7 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<layout 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">
<data>
<variable
name="model"
type="com.xyz.babelive.viewModel.home.MainViewModel" />
</data>
<androidx.core.widget.NestedScrollView
android:id="@+id/scrollView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/default_bg">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<VideoView
android:layout_width="0dp"
android:layout_height="0dp"
android:id="@+id/video"
app:layout_constraintDimensionRatio="375:180"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:layout_width="0dp"
android:layout_height="0dp"
android:id="@+id/cover_iv"
android:src="@mipmap/zanwei"
android:scaleType="centerCrop"
app:layout_constraintDimensionRatio="375:180"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="@dimen/dp28"
android:id="@+id/cover_tv"
android:gravity="center"
android:textSize="12sp"
android:textStyle="bold"
android:paddingStart="10dp"
android:paddingEnd="@dimen/dp10"
android:textColor="@color/white"
android:background="@drawable/card_bord_bantou_bg"
android:text="@string/enter_streaming_room"
app:layout_constraintDimensionRatio="1920:1080"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"/>
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/tab_rv"
android:layout_width="match_parent"
android:layout_height="118dp" />
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/dp10">
<androidx.recyclerview.widget.RecyclerView
android:layout_width="match_parent"
android:layout_height="114dp"
android:layout_marginStart="@dimen/dp10"
android:layout_marginEnd="@dimen/dp10"
android:id="@+id/rvuser"
android:background="@drawable/card_bord_org_bg"
android:layout_marginTop="@dimen/dp14" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="@dimen/dp28"
android:background="@mipmap/img_bg_hot"
android:gravity="center"
android:layout_centerHorizontal="true"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textSize="@dimen/sp16"
android:textStyle="bold"
android:gravity="center"
android:drawableLeft="@mipmap/img_cb_l"
android:drawableRight="@mipmap/img_cb_r"
android:drawablePadding="@dimen/dp5"
android:textColor="@color/white"
android:text="@string/hot_anchor"/>
</LinearLayout>
</RelativeLayout>
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<androidx.cardview.widget.CardView
android:id="@+id/cameraView"
android:layout_width="0dp"
android:layout_height="0dp"
app:cardBackgroundColor="@color/main_color"
app:cardCornerRadius="@dimen/dp5"
app:cardElevation="@dimen/dp0"
android:layout_margin="10dp"
app:layout_constraintDimensionRatio="1980:180"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent">
<com.youth.banner.Banner
android:id="@+id/banner"
android:layout_width="match_parent"
android:layout_height="match_parent"
/>
</androidx.cardview.widget.CardView>
</androidx.constraintlayout.widget.ConstraintLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/dp10"
android:drawableLeft="@mipmap/icon_live02"
android:gravity="center_vertical"
android:text="@string/live_now"
android:drawablePadding="@dimen/dp5"
android:textColor="@color/body_txt_color"
android:textSize="16sp"
/>
<androidx.recyclerview.widget.RecyclerView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingStart="@dimen/dp5"
android:paddingRight="@dimen/dp5"
android:id="@+id/rv"/>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</layout>