LibreTube/app/src/main/res/layout/downloaded_media_row.xml

94 lines
3.5 KiB
XML
Raw Normal View History

2022-09-09 17:53:39 +05:30
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
2022-10-15 19:59:12 +05:30
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
2022-09-09 17:53:39 +05:30
android:layout_width="match_parent"
2022-09-09 18:12:46 +05:30
android:layout_height="wrap_content"
2022-09-09 20:19:00 +05:30
android:background="?attr/selectableItemBackground"
2022-09-09 17:53:39 +05:30
android:orientation="horizontal"
2022-09-09 18:12:46 +05:30
android:paddingHorizontal="10dp"
android:paddingVertical="8dp">
2022-09-09 17:53:39 +05:30
2022-10-15 19:59:12 +05:30
<com.google.android.material.card.MaterialCardView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginEnd="15dp"
app:cardCornerRadius="8dp">
<ImageView
android:id="@+id/thumbnailImage"
android:layout_width="140dp"
android:layout_height="80dp"
android:scaleType="fitXY"
tools:src="@tools:sample/backgrounds/scenic" />
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/downloadOverlay"
android:layout_width="140dp"
android:layout_height="80dp"
android:background="#BF000000">
<ProgressBar
android:id="@+id/progressBar"
android:layout_width="52dp"
android:layout_height="52dp"
android:indeterminateOnly="false"
android:progressDrawable="@drawable/circular_progress"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/resumePauseBtn"
android:layout_width="24dp"
android:layout_height="24dp"
android:src="@drawable/ic_download"
app:layout_constraintBottom_toBottomOf="@id/progressBar"
app:layout_constraintLeft_toLeftOf="@id/progressBar"
app:layout_constraintRight_toRightOf="@id/progressBar"
app:layout_constraintTop_toTopOf="@id/progressBar" />
</androidx.constraintlayout.widget.ConstraintLayout>
2022-10-15 19:59:12 +05:30
</com.google.android.material.card.MaterialCardView>
2022-10-10 20:28:26 +05:30
<LinearLayout
2022-09-09 17:53:39 +05:30
android:layout_width="0dp"
2022-10-10 20:28:26 +05:30
android:layout_height="wrap_content"
2022-10-15 19:59:12 +05:30
android:layout_marginEnd="10dp"
2022-10-10 20:33:03 +05:30
android:layout_weight="1"
2022-10-15 19:59:12 +05:30
android:orientation="vertical">
2022-10-10 20:28:26 +05:30
<TextView
android:id="@+id/title"
2022-10-10 20:28:26 +05:30
android:layout_width="match_parent"
android:layout_height="wrap_content"
2022-10-10 20:33:03 +05:30
android:layout_marginVertical="2dp"
2022-10-15 19:59:12 +05:30
android:maxLines="2"
2022-10-10 20:33:03 +05:30
android:textSize="16sp" />
2022-10-10 20:28:26 +05:30
<TextView
android:id="@+id/uploaderName"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2022-10-10 20:33:03 +05:30
android:layout_marginVertical="2dp"
2022-10-10 20:28:26 +05:30
android:textSize="12sp" />
<TextView
android:id="@+id/videoInfo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
2022-10-10 20:33:03 +05:30
android:layout_marginVertical="2dp"
2022-10-10 20:28:26 +05:30
android:textSize="12sp" />
</LinearLayout>
2022-09-09 17:53:39 +05:30
<TextView
android:id="@+id/fileSize"
android:layout_width="64dp"
2022-10-10 20:33:03 +05:30
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:textSize="13sp" />
2022-09-09 17:53:39 +05:30
</LinearLayout>