52 lines
No EOL
2.1 KiB
XML
52 lines
No EOL
2.1 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"
|
|
tools:context=".ui.GenreViewHolder">
|
|
|
|
<data>
|
|
|
|
<variable
|
|
name="genre"
|
|
type="org.oxycblt.auxio.music.Genre" />
|
|
</data>
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout style="@style/Widget.Auxio.ItemLayout">
|
|
|
|
<ImageView
|
|
android:id="@+id/genre_image"
|
|
style="@style/Widget.Auxio.Image.Medium"
|
|
android:contentDescription="@{@string/desc_genre_image(genre.resolvedName)}"
|
|
app:genreImage="@{genre}"
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
tools:src="@drawable/ic_genre" />
|
|
|
|
<TextView
|
|
android:id="@+id/genre_name"
|
|
style="@style/Widget.Auxio.TextView.Item.Primary"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:text="@{genre.resolvedName}"
|
|
app:layout_constraintBottom_toTopOf="@+id/genre_count"
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
|
app:layout_constraintTop_toTopOf="parent"
|
|
app:layout_constraintVertical_chainStyle="packed"
|
|
tools:text="Genre Name" />
|
|
|
|
<TextView
|
|
android:id="@+id/genre_count"
|
|
style="@style/Widget.Auxio.TextView.Item.Secondary"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:text="@{@plurals/fmt_song_count(genre.songs.size(), genre.songs.size())}"
|
|
app:layout_constraintBottom_toBottomOf="parent"
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
|
app:layout_constraintTop_toBottomOf="@+id/genre_name"
|
|
tools:text="40 Songs" />
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
</layout> |