history_item.xml 3.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3. xmlns:app="http://schemas.android.com/apk/res-auto"
  4. xmlns:tools="http://schemas.android.com/tools"
  5. android:id="@+id/holder"
  6. android:layout_width="match_parent"
  7. android:layout_height="96dp"
  8. android:paddingStart="16dp"
  9. android:paddingTop="8dp"
  10. android:paddingEnd="8dp"
  11. android:paddingBottom="8dp"
  12. android:background="?attr/selectableItemBackground"
  13. android:orientation="horizontal">
  14. <com.google.android.material.imageview.ShapeableImageView
  15. android:id="@+id/cover"
  16. android:layout_width="0dp"
  17. android:layout_height="match_parent"
  18. android:contentDescription="@string/description_cover"
  19. android:scaleType="centerCrop"
  20. app:layout_constraintBottom_toBottomOf="parent"
  21. app:layout_constraintDimensionRatio="h,3:2"
  22. app:layout_constraintStart_toStartOf="parent"
  23. app:layout_constraintTop_toTopOf="parent"
  24. app:shapeAppearance="@style/ShapeAppearanceOverlay.Cover"
  25. tools:src="@mipmap/ic_launcher" />
  26. <LinearLayout
  27. android:layout_width="0dp"
  28. android:layout_height="wrap_content"
  29. android:layout_marginStart="16dp"
  30. android:layout_marginEnd="8dp"
  31. android:orientation="vertical"
  32. app:layout_constraintBottom_toBottomOf="parent"
  33. app:layout_constraintEnd_toStartOf="@+id/remove"
  34. app:layout_constraintStart_toEndOf="@+id/cover"
  35. app:layout_constraintTop_toTopOf="parent">
  36. <TextView
  37. android:id="@+id/manga_title"
  38. android:layout_width="match_parent"
  39. android:layout_height="wrap_content"
  40. android:ellipsize="end"
  41. android:maxLines="2"
  42. android:textAppearance="?attr/textAppearanceSubtitle2"
  43. tools:text="Title" />
  44. <TextView
  45. android:id="@+id/manga_subtitle"
  46. android:layout_width="match_parent"
  47. android:layout_height="wrap_content"
  48. android:layout_marginTop="2dp"
  49. android:textAppearance="?attr/textAppearanceBody2"
  50. android:textColor="?android:attr/textColorSecondary"
  51. tools:text="Subtitle" />
  52. </LinearLayout>
  53. <ImageButton
  54. android:id="@+id/remove"
  55. android:layout_width="wrap_content"
  56. android:layout_height="wrap_content"
  57. android:background="?attr/selectableItemBackgroundBorderless"
  58. android:contentDescription="@string/action_resume"
  59. android:padding="8dp"
  60. app:layout_constraintBottom_toBottomOf="parent"
  61. app:layout_constraintEnd_toStartOf="@+id/resume"
  62. app:layout_constraintTop_toTopOf="parent"
  63. app:srcCompat="@drawable/ic_delete_24dp"
  64. app:tint="?android:attr/textColorPrimary" />
  65. <ImageButton
  66. android:id="@+id/resume"
  67. android:layout_width="wrap_content"
  68. android:layout_height="wrap_content"
  69. android:background="?attr/selectableItemBackgroundBorderless"
  70. android:contentDescription="@string/action_resume"
  71. android:padding="8dp"
  72. app:layout_constraintBottom_toBottomOf="parent"
  73. app:layout_constraintEnd_toEndOf="parent"
  74. app:layout_constraintTop_toTopOf="parent"
  75. app:srcCompat="@drawable/ic_play_arrow_24dp"
  76. app:tint="?android:attr/textColorPrimary" />
  77. </androidx.constraintlayout.widget.ConstraintLayout>