layout_list_item.xml raw

   1  <androidx.cardview.widget.CardView xmlns:android="http://schemas.android.com/apk/res/android"
   2      xmlns:tools="http://schemas.android.com/tools"
   3      xmlns:app="http://schemas.android.com/apk/res-auto"
   4      android:layout_width="wrap_content"
   5      android:layout_height="wrap_content"
   6      android:layout_marginHorizontal="4dp"
   7      android:layout_marginBottom="16dp"
   8      app:cardCornerRadius="@dimen/common_corner_radius"
   9      app:cardElevation="0dp"
  10      app:cardBackgroundColor="@android:color/transparent"
  11      tools:ignore="UseCompoundDrawables">
  12  
  13      <LinearLayout
  14          android:id="@+id/linearLayout"
  15          android:layout_width="match_parent"
  16          android:layout_height="match_parent"
  17          android:padding="@dimen/icon_margin"
  18          android:background="?selectableItemBackground"
  19          android:orientation="vertical">
  20  
  21          <ImageView
  22              android:id="@+id/drawable"
  23              android:layout_width="@dimen/big_icon_size"
  24              android:layout_height="@dimen/big_icon_size"
  25              android:layout_marginBottom="@dimen/icon_margin"
  26              android:contentDescription="@null" />
  27  
  28          <TextView
  29              android:id="@+id/title"
  30              android:layout_width="match_parent"
  31              android:layout_height="wrap_content"
  32              android:ellipsize="end"
  33              android:gravity="center"
  34              android:textColor="?android:attr/textColorPrimary"
  35              android:textIsSelectable="false" />
  36      </LinearLayout>
  37  </androidx.cardview.widget.CardView>