detail: refactor module
Completely refactor the detail module. This is for a few reasons: - Prevent data regeneration every time a fragment re-creates. - Make DetailModel follow the customs of other ViewModels. - Simplify layouts into a single detail item to reduce code complexity. Currently sorting doesn't work, but that is still being worked out as the legacy SortMode continues to be phased out of Auxio.
This commit is contained in:
@@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM21.41 6.34l-3.75-3.75-2.53 2.54 3.75 3.75 2.53-2.54z" />
|
||||
</vector>
|
||||
@@ -2,7 +2,7 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:tint="?attr/colorControlNormal"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M3.694 17.992H0.976l4.142-12h3.27l4.136 12H9.806L6.8 8.734H6.706zm-0.17-4.717h6.422v1.98H3.524zm10.313 4.717v-1.506l5.988-8.402h-6V5.992h9.188v1.505L17.018 15.9h6.006v2.092z" />
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M15.5 20.535h-7l3.5 3.456 3.5-3.456z" />
|
||||
</vector>
|
||||
@@ -1,13 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M15.5 3.448h-7L12-0.008l3.5 3.456z" />
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M3.694 17.992H0.976l4.142-12h3.27l4.136 12H9.806L6.8 8.734H6.706zm-0.17-4.717h6.422v1.98H3.524zm10.313 4.717v-1.506l5.988-8.402h-6V5.992h9.188v1.505L17.018 15.9h6.006v2.092z" />
|
||||
</vector>
|
||||
@@ -1,15 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?android:attr/colorAccent"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M6.542 18q-1.508-0.006-2.595-0.716-1.082-0.711-1.667-2.06-0.578-1.348-0.573-3.244 0-1.89 0.58-3.221 0.584-1.331 1.665-2.025 1.088-0.7 2.59-0.7 1.503 0 2.584 0.7 1.088 0.7 1.673 2.03 0.584 1.326 0.578 3.216 0 1.902-0.584 3.25-0.579 1.348-1.66 2.06Q8.05 18 6.542 18zm0-2.025q1.03 0 1.643-0.999 0.614-0.998 0.608-2.996 0-1.314-0.28-2.188-0.275-0.875-0.784-1.315-0.503-0.44-1.187-0.44-1.023 0-1.637 0.987-0.614 0.988-0.62 2.957 0 1.33 0.276 2.222 0.28 0.886 0.789 1.332 0.508 0.44 1.193 0.44zM17.51 6q0.924 0 1.777 0.3 0.86 0.293 1.532 0.953 0.679 0.66 1.07 1.749 0.398 1.083 0.404 2.668-0.006 1.472-0.351 2.629-0.34 1.15-0.976 1.958-0.638 0.806-1.538 1.23-0.895 0.417-2.005 0.417-1.199 0-2.117-0.446-0.918-0.45-1.479-1.224-0.555-0.779-0.672-1.749h2.496q0.146 0.632 0.614 0.982 0.468 0.344 1.158 0.344 1.169 0 1.777-0.982 0.608-0.987 0.614-2.702h-0.082Q19.463 12.635 19.007 13q-0.456 0.362-1.046 0.559-0.585 0.197-1.246 0.197-1.058 0-1.894-0.48-0.83-0.479-1.31-1.32-0.479-0.846-0.473-1.929-0.006-1.173 0.555-2.082 0.562-0.914 1.567-1.433Q16.172 5.994 17.51 6zm0.018 1.918q-0.59 0-1.053 0.271Q16.02 8.46 15.75 8.923q-0.263 0.462-0.257 1.038-0.006 0.575 0.252 1.032 0.263 0.457 0.719 0.728 0.456 0.265 1.04 0.265 0.439 0 0.807-0.158 0.374-0.158 0.65-0.434 0.28-0.282 0.438-0.65 0.158-0.372 0.163-0.795-0.005-0.558-0.269-1.02-0.263-0.463-0.725-0.734-0.461-0.277-1.04-0.277z"
|
||||
tools:ignore="VectorPath" />
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M15.5 20.544h-7L12 24l3.5-3.456z" />
|
||||
</vector>
|
||||
@@ -1,15 +0,0 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:tint="?attr/colorAccent"
|
||||
android:viewportWidth="24"
|
||||
android:viewportHeight="24">
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M6.542 18q-1.508-0.006-2.595-0.716-1.082-0.711-1.667-2.06-0.578-1.348-0.573-3.244 0-1.89 0.58-3.221 0.584-1.331 1.665-2.025 1.088-0.7 2.59-0.7 1.503 0 2.584 0.7 1.088 0.7 1.673 2.03 0.584 1.326 0.578 3.216 0 1.902-0.584 3.25-0.579 1.348-1.66 2.06Q8.05 18 6.542 18zm0-2.025q1.03 0 1.643-0.999 0.614-0.998 0.608-2.996 0-1.314-0.28-2.188-0.275-0.875-0.784-1.315-0.503-0.44-1.187-0.44-1.023 0-1.637 0.987-0.614 0.988-0.62 2.957 0 1.33 0.276 2.222 0.28 0.886 0.789 1.332 0.508 0.44 1.193 0.44zM17.51 6q0.924 0 1.777 0.3 0.86 0.293 1.532 0.953 0.679 0.66 1.07 1.749 0.398 1.083 0.404 2.668-0.006 1.472-0.351 2.629-0.34 1.15-0.976 1.958-0.638 0.806-1.538 1.23-0.895 0.417-2.005 0.417-1.199 0-2.117-0.446-0.918-0.45-1.479-1.224-0.555-0.779-0.672-1.749h2.496q0.146 0.632 0.614 0.982 0.468 0.344 1.158 0.344 1.169 0 1.777-0.982 0.608-0.987 0.614-2.702h-0.082Q19.463 12.635 19.007 13q-0.456 0.362-1.046 0.559-0.585 0.197-1.246 0.197-1.058 0-1.894-0.48-0.83-0.479-1.31-1.32-0.479-0.846-0.473-1.929-0.006-1.173 0.555-2.082 0.562-0.914 1.567-1.433Q16.172 5.994 17.51 6zm0.018 1.918q-0.59 0-1.053 0.271Q16.02 8.46 15.75 8.923q-0.263 0.462-0.257 1.038-0.006 0.575 0.252 1.032 0.263 0.457 0.719 0.728 0.456 0.265 1.04 0.265 0.439 0 0.807-0.158 0.374-0.158 0.65-0.434 0.28-0.282 0.438-0.65 0.158-0.372 0.163-0.795-0.005-0.558-0.269-1.02-0.263-0.463-0.725-0.734-0.461-0.277-1.04-0.277z"
|
||||
tools:ignore="VectorPath" />
|
||||
<path
|
||||
android:fillColor="@android:color/white"
|
||||
android:pathData="M15.5 3.456h-7L12 0l3.5 3.456z" />
|
||||
</vector>
|
||||
@@ -7,7 +7,7 @@
|
||||
<shape android:shape="rectangle">
|
||||
<stroke
|
||||
android:width="@dimen/size_stroke_small"
|
||||
android:color="@color/overlay_divider" />
|
||||
android:color="@color/mtrl_btn_stroke_color_selector" />
|
||||
</shape>
|
||||
</item>
|
||||
</layer-list>
|
||||
|
||||
@@ -1,137 +0,0 @@
|
||||
<?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="album"
|
||||
type="org.oxycblt.auxio.music.Album" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:animateLayoutChanges="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/album_cover"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge_land"
|
||||
android:layout_height="@dimen/size_cover_huge_land"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_album_cover(album.name)}"
|
||||
app:albumArt="@{album}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_album" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{album.name}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/album_artist"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_cover"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Album Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_artist"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:onClick="@{() -> detailModel.navToItem(album.artist)}"
|
||||
android:text="@{album.artist.name}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/album_details"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_name"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_details"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:albumDetails="@{album}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_cover"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_artist"
|
||||
tools:text="2020 / 10 Songs / 16:16" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/album_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_cover" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_song_header"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:background="@drawable/ui_header_dividers"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/album_sort_button"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementAlbumSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_song_header"
|
||||
app:sortIcon="@{detailModel.albumSortMode}"
|
||||
tools:src="@drawable/ic_sort_numeric_down" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,114 +0,0 @@
|
||||
<?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=".detail.adapters.ArtistDetailAdapter.ArtistHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="artist"
|
||||
type="org.oxycblt.auxio.music.Artist" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/artist_image"
|
||||
android:layout_width="@dimen/size_cover_huge_land"
|
||||
android:layout_height="@dimen/size_cover_huge_land"
|
||||
android:layout_margin="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_artist_image(artist.name)}"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:artistImage="@{artist}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{artist.name}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/artist_genre"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toTopOf="@+id/artist_image"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_genre"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistGenre="@{artist}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/artist_counts"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_name"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_counts"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistCounts="@{artist}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/artist_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_genre"
|
||||
tools:text="2 Albums, 20 Songs" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toStartOf="@+id/artist_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_image" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/artist_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/artist_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_album_header"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:text="@string/lbl_albums"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_play_button" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</layout>
|
||||
@@ -0,0 +1,87 @@
|
||||
<?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">
|
||||
|
||||
<!-- This layout is re-used across all detail fragments. Do not add databinding. -->
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="@dimen/spacing_medium">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/detail_cover"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge_land"
|
||||
android:layout_height="@dimen/size_cover_huge_land"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toTopOf="@+id/detail_subhead"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toTopOf="@+id/detail_cover"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_subhead"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/detail_info"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_name"
|
||||
tools:text="Info A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_info"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/detail_cover"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_subhead"
|
||||
tools:text="Info B" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/detail_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_cover" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:text="@string/lbl_shuffle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/detail_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/detail_play_button" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,131 +0,0 @@
|
||||
<?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=".detail.adapters.GenreDetailAdapter.GenreHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="genre"
|
||||
type="org.oxycblt.auxio.music.Genre" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/genre_image"
|
||||
android:layout_width="@dimen/size_cover_huge_land"
|
||||
android:layout_height="@dimen/size_cover_huge_land"
|
||||
android:layout_margin="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_genre_image(genre.name)}"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:genreImage="@{genre}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_genre" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{genre.resolvedName}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/genre_song_count"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_image"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_count"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{@plurals/fmt_song_count(genre.songs.size(), genre.songs.size())}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/genre_duration"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_name"
|
||||
tools:text="2 Artists, 4 Albums" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toStartOf="@+id/genre_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_image" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_duration"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{genre.totalDuration}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_song_count"
|
||||
tools:text="16:16" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/genre_sort_button"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementGenreSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_song_header"
|
||||
app:sortIcon="@{detailModel.genreSortMode}"
|
||||
tools:src="@drawable/ic_sort_alpha_down" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,136 +0,0 @@
|
||||
<?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="album"
|
||||
type="org.oxycblt.auxio.music.Album" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:animateLayoutChanges="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/album_cover"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_album_cover(album.name)}"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:albumArt="@{album}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_album" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{album.name}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/album_artist"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_cover"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Album Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_artist"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:onClick="@{() -> detailModel.navToItem(album.artist)}"
|
||||
android:text="@{album.artist.name}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/album_details"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_name"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_details"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:albumDetails="@{album}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_cover"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_artist"
|
||||
tools:text="2020 / 10 Songs / 16:16" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toStartOf="@+id/album_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_cover" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_song_header"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:background="@drawable/ui_header_dividers"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/album_sort_button"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementAlbumSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_song_header"
|
||||
app:sortIcon="@{detailModel.albumSortMode}"
|
||||
tools:src="@drawable/ic_sort_numeric_down" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,114 +0,0 @@
|
||||
<?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=".detail.adapters.ArtistDetailAdapter.ArtistHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="artist"
|
||||
type="org.oxycblt.auxio.music.Artist" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/artist_image"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_margin="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_artist_image(artist.name)}"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:artistImage="@{artist}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{artist.name}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/artist_genre"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toTopOf="@+id/artist_image"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_genre"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistGenre="@{artist}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/artist_counts"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_name"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_counts"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistCounts="@{artist}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/artist_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_genre"
|
||||
tools:text="2 Albums, 20 Songs" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toStartOf="@+id/artist_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_image" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/artist_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/artist_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_album_header"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:text="@string/lbl_albums"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_play_button" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</layout>
|
||||
@@ -0,0 +1,84 @@
|
||||
<?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">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="@dimen/spacing_medium">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/detail_cover"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toTopOf="@+id/detail_subhead"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toTopOf="@+id/detail_cover"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_subhead"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/detail_info"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_name"
|
||||
tools:text="Info A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_info"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/detail_cover"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_cover"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_subhead"
|
||||
tools:text="Info B" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
app:layout_constraintEnd_toStartOf="@+id/detail_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_cover" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/detail_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/detail_play_button" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,129 +0,0 @@
|
||||
<?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=".detail.adapters.GenreDetailAdapter.GenreHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="genre"
|
||||
type="org.oxycblt.auxio.music.Genre" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/genre_image"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_margin="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_genre_image(genre.name)}"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
app:genreImage="@{genre}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_genre" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{genre.resolvedName}"
|
||||
app:layout_constraintBottom_toTopOf="@+id/genre_song_count"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_image"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_count"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{@plurals/fmt_song_count(genre.songs.size(), genre.songs.size())}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toTopOf="@+id/genre_duration"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_name"
|
||||
tools:text="2 Artists, 4 Albums" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toStartOf="@+id/genre_shuffle_button"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_image" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_duration"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{genre.totalDuration}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_image"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_image"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_song_count"
|
||||
tools:text="16:16" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/genre_sort_button"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementGenreSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_song_header"
|
||||
app:sortIcon="@{detailModel.genreSortMode}"
|
||||
tools:src="@drawable/ic_sort_alpha_down" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -29,6 +29,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:clipToPadding="false"
|
||||
android:theme="@style/Theme.Neutral"
|
||||
app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior">
|
||||
|
||||
<com.google.android.material.card.MaterialCardView
|
||||
@@ -38,7 +39,7 @@
|
||||
app:cardBackgroundColor="?attr/colorSurface"
|
||||
app:cardCornerRadius="0dp"
|
||||
app:cardElevation="0dp"
|
||||
app:strokeColor="@color/overlay_divider"
|
||||
app:strokeColor="@color/mtrl_btn_stroke_color_selector"
|
||||
app:strokeWidth="1dp">
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -158,7 +159,6 @@
|
||||
<TextView
|
||||
android:id="@+id/about_song_count"
|
||||
style="@style/Widget.TextView.Icon"
|
||||
android:theme="@style/Theme.Neutral"
|
||||
app:drawableStartCompat="@drawable/ic_song"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
@@ -169,7 +169,7 @@
|
||||
android:id="@+id/about_author"
|
||||
style="@style/Widget.TextView.Icon"
|
||||
android:text="@string/lbl_author"
|
||||
app:drawableStartCompat="@drawable/ic_author"
|
||||
app:drawableStartCompat="@drawable/ic_artist"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/about_song_count" />
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
style="@style/Widget.TextView.Compact.Secondary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:text="@{@string/format_info(song.album.artist.name, song.album.name)}"
|
||||
android:text="@{@string/fmt_two(song.album.artist.name, song.album.name)}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/playback_cover"
|
||||
app:layout_constraintEnd_toStartOf="@+id/playback_play_pause"
|
||||
app:layout_constraintStart_toEndOf="@+id/playback_cover"
|
||||
|
||||
@@ -28,8 +28,7 @@
|
||||
android:layout_height="match_parent"
|
||||
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
|
||||
app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior"
|
||||
tools:listitem="@layout/item_artist_header"
|
||||
tools:layout_marginTop="56dp"/>
|
||||
tools:listitem="@layout/item_detail" />
|
||||
|
||||
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
||||
</layout>
|
||||
@@ -4,12 +4,11 @@
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
tools:context=".ui.HeaderViewHolder">
|
||||
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="header"
|
||||
type="org.oxycblt.auxio.music.Header" />
|
||||
type="org.oxycblt.auxio.music.ActionHeader" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -32,10 +31,12 @@
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:contentDescription="@{context.getString(header.desc)}"
|
||||
android:src="@{context.getDrawable(header.icon)}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:ignore="ContentDescription"
|
||||
tools:src="@drawable/ic_clear" />
|
||||
tools:src="@drawable/ic_sort"/>
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -37,7 +37,7 @@
|
||||
<TextView
|
||||
android:id="@+id/album_info"
|
||||
style="@style/Widget.TextView.Item.Secondary"
|
||||
app:albumInfo="@{album}"
|
||||
android:text="@{@string/fmt_two(album.artist.name, @plurals/fmt_song_count(album.songs.size, album.songs.size))}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
|
||||
@@ -1,128 +0,0 @@
|
||||
<?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="album"
|
||||
type="org.oxycblt.auxio.music.Album" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:animateLayoutChanges="true">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/album_cover"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_album_cover(album.name)}"
|
||||
app:albumArt="@{album}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_album" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{album.name}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_cover"
|
||||
tools:text="Album Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_artist"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:onClick="@{() -> detailModel.navToItem(album.artist)}"
|
||||
android:text="@{album.artist.name}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_name"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_details"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:albumDetails="@{album}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_artist"
|
||||
tools:text="2020 / 10 Songs / 16:16" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/album_shuffle_button"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_details" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/album_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playAlbum(album, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/album_song_header"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:background="@drawable/ui_header_dividers"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/album_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/album_sort_button"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementAlbumSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/album_song_header"
|
||||
app:sortIcon="@{detailModel.albumSortMode}"
|
||||
tools:src="@drawable/ic_sort_numeric_down" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -2,7 +2,7 @@
|
||||
<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=".detail.adapters.AlbumDetailAdapter.AlbumSongViewHolder">
|
||||
tools:context=".detail.recycler.AlbumDetailAdapter.AlbumSongViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<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=".detail.adapters.ArtistDetailAdapter.ArtistAlbumViewHolder">
|
||||
tools:context=".detail.recycler.ArtistDetailAdapter.ArtistAlbumViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
<TextView
|
||||
android:id="@+id/album_year"
|
||||
style="@style/Widget.TextView.Item.Secondary"
|
||||
app:albumYear="@{album}"
|
||||
android:text="@{album.year != 0 ? String.valueOf(album.year) : @string/def_date}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
|
||||
@@ -1,114 +0,0 @@
|
||||
<?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=".detail.adapters.ArtistDetailAdapter.ArtistHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="artist"
|
||||
type="org.oxycblt.auxio.music.Artist" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/artist_image"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_artist_image(artist.name)}"
|
||||
app:artistImage="@{artist}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{artist.name}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_image"
|
||||
tools:text="Artist Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_genre"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistGenre="@{artist}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_name"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_counts"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:artistCounts="@{artist}"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_genre"
|
||||
tools:text="2 Albums, 20 Songs" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/artist_shuffle_button"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_counts" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/artist_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playArtist(artist, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/artist_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/artist_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/artist_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/artist_song_header"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:background="@drawable/ui_header_dividers"
|
||||
android:text="@string/lbl_albums"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/artist_play_button" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</layout>
|
||||
@@ -0,0 +1,78 @@
|
||||
<?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">
|
||||
|
||||
<!-- This layout is re-used across all detail fragments. Do not add databinding. -->
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:padding="@dimen/spacing_medium">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/detail_cover"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_artist"
|
||||
tools:ignore="ContentDescription" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_cover"
|
||||
tools:text="Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_subhead"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_name"
|
||||
tools:text="Info A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/detail_info"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_subhead"
|
||||
tools:text="Info B" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/detail_shuffle_button"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/detail_info" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/detail_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:layout_marginStart="@dimen/spacing_small"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:text="@string/lbl_shuffle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/detail_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/detail_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/detail_play_button" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -1,126 +0,0 @@
|
||||
<?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=".detail.adapters.GenreDetailAdapter.GenreHeaderViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
<variable
|
||||
name="genre"
|
||||
type="org.oxycblt.auxio.music.Genre" />
|
||||
|
||||
<variable
|
||||
name="detailModel"
|
||||
type="org.oxycblt.auxio.detail.DetailViewModel" />
|
||||
|
||||
<variable
|
||||
name="playbackModel"
|
||||
type="org.oxycblt.auxio.playback.PlaybackViewModel" />
|
||||
|
||||
</data>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/genre_image"
|
||||
style="@style/Widget.ImageView.Full"
|
||||
android:layout_width="@dimen/size_cover_huge"
|
||||
android:layout_height="@dimen/size_cover_huge"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:contentDescription="@{@string/desc_genre_image(genre.name)}"
|
||||
app:genreImage="@{genre}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:src="@drawable/ic_genre" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatTextView
|
||||
android:id="@+id/genre_name"
|
||||
style="@style/Widget.TextView.Detail"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_medium"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{genre.resolvedName}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHorizontal_bias="0.5"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_image"
|
||||
tools:text="Genre Name" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_count"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{@plurals/fmt_song_count(genre.songs.size(), genre.songs.size())}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_name"
|
||||
tools:text="80 Songs" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_duration"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:text="@{genre.totalDuration}"
|
||||
android:textAppearance="?android:attr/textAppearanceListItem"
|
||||
android:textColor="?android:attr/textColorSecondary"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_song_count"
|
||||
tools:text="16:16" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_play_button"
|
||||
style="@style/Widget.Button.Vibrant.Secondary"
|
||||
android:layout_marginStart="@dimen/spacing_medium"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, false)}"
|
||||
android:text="@string/lbl_play"
|
||||
app:layout_constraintEnd_toStartOf="@+id/genre_shuffle_button"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_duration" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
android:id="@+id/genre_shuffle_button"
|
||||
style="@style/Widget.Button.Vibrant.Primary"
|
||||
android:backgroundTint="?attr/colorAccent"
|
||||
android:onClick="@{() -> playbackModel.playGenre(genre, true)}"
|
||||
android:text="@string/lbl_shuffle"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_play_button"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/genre_play_button"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_play_button" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/genre_song_header"
|
||||
style="@style/Widget.TextView.Header"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/spacing_small"
|
||||
android:text="@string/lbl_songs"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/genre_play_button" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/genre_sort_button"
|
||||
style="@style/Widget.Button.Unbounded.Small"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:contentDescription="@string/desc_sort_button"
|
||||
android:onClick="@{() -> detailModel.incrementGenreSortMode()}"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/genre_song_header"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/genre_song_header"
|
||||
app:sortIcon="@{detailModel.genreSortMode}"
|
||||
tools:src="@drawable/ic_sort_alpha_down" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
</layout>
|
||||
@@ -2,7 +2,7 @@
|
||||
<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=".detail.adapters.GenreDetailAdapter.GenreSongViewHolder">
|
||||
tools:context=".detail.recycler.GenreDetailAdapter.GenreSongViewHolder">
|
||||
|
||||
<data>
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
android:id="@+id/song_info"
|
||||
style="@style/Widget.TextView.Item.Secondary"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{@string/format_info(song.album.artist.name, song.album.name)}"
|
||||
android:text="@{@string/fmt_two(song.album.artist.name, song.album.name)}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/song_duration"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
android:id="@+id/song_info"
|
||||
style="@style/Widget.TextView.Item.Secondary"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{@string/format_info(song.album.artist.name, song.album.name)}"
|
||||
android:text="@{@string/fmt_two(song.album.artist.name, song.album.name)}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/song_drag_handle"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
@@ -52,13 +52,14 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/song_drag_handle"
|
||||
android:layout_width="@dimen/size_btn_small"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/size_btn_small"
|
||||
android:layout_marginEnd="@dimen/spacing_small"
|
||||
android:clickable="true"
|
||||
android:contentDescription="@string/desc_queue_handle"
|
||||
android:focusable="true"
|
||||
android:scaleType="center"
|
||||
android:paddingStart="@dimen/spacing_medium"
|
||||
android:paddingEnd="@dimen/spacing_medium"
|
||||
android:src="@drawable/ic_handle"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/album_cover"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
android:id="@+id/song_info"
|
||||
style="@style/Widget.TextView.Item.Secondary"
|
||||
android:layout_marginEnd="@dimen/spacing_medium"
|
||||
android:text="@{@string/format_info(song.album.artist.name, song.album.name)}"
|
||||
android:text="@{@string/fmt_two(song.album.artist.name, song.album.name)}"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/album_cover"
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<group android:checkableBehavior="single">
|
||||
<item
|
||||
android:id="@+id/option_sort_asc"
|
||||
android:title="@string/lbl_sort_asc" />
|
||||
<item
|
||||
android:id="@+id/option_sort_dsc"
|
||||
android:title="@string/lbl_sort_dsc" />
|
||||
<item
|
||||
android:id="@+id/option_sort_artist"
|
||||
android:title="@string/lbl_sort_artist" />
|
||||
<item
|
||||
android:id="@+id/option_sort_album"
|
||||
android:title="@string/lbl_sort_album" />
|
||||
<item
|
||||
android:id="@+id/option_sort_year"
|
||||
android:title="@string/lbl_sort_year" />
|
||||
</group>
|
||||
</menu>
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
<item
|
||||
android:id="@+id/submenu_sorting"
|
||||
android:icon="@drawable/ic_sort_none"
|
||||
android:icon="@drawable/ic_sort"
|
||||
android:title="@string/lbl_sort"
|
||||
app:showAsAction="ifRoom">
|
||||
<menu>
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
<string name="hint_search_library">"Prohledat vaši knihovnu…"</string>
|
||||
|
||||
<!-- Description Namespace | Accessibility Strings -->
|
||||
<string name="desc_sort_button">"Změnit pořadí řazení"</string>
|
||||
<string name="desc_sort">"Změnit pořadí řazení"</string>
|
||||
<string name="desc_track_number">"Stopa %d"</string>
|
||||
<string name="desc_play_pause">"Přehrát nebo pozastavit"</string>
|
||||
<string name="desc_skip_next">"Přeskočit na další skladbu"</string>
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
<string name="hint_search_library">Musikbibliothek durchsuchen…</string>
|
||||
|
||||
<!-- Description Namespace | Accessibility Strings -->
|
||||
<string name="desc_sort_button">Reihenfolge ändern</string>
|
||||
<string name="desc_sort">Reihenfolge ändern</string>
|
||||
<string name="desc_track_number">Titel %d</string>
|
||||
|
||||
<string name="desc_play_pause">Abspielen oder Pausieren</string>
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
<string name="hint_search_library">Busca en tu biblioteca…</string>
|
||||
|
||||
<!-- Description Namespace | Accessibility Strings -->
|
||||
<string name="desc_sort_button">Cambiar el orden de clasificación</string>
|
||||
<string name="desc_sort">Cambiar el orden de clasificación</string>
|
||||
<string name="desc_track_number">Pista %d</string>
|
||||
|
||||
<string name="desc_play_pause">Reproducir o Pausar</string>
|
||||
|
||||
@@ -104,7 +104,7 @@
|
||||
<string name="hint_search_library">Zoek in uw bibliotheek…</string>
|
||||
|
||||
<!-- Description Namespace | Accessibility Strings -->
|
||||
<string name="desc_sort_button">Sorteervolgorde wijzigen</string>
|
||||
<string name="desc_sort">Sorteervolgorde wijzigen</string>
|
||||
<string name="desc_track_number">Nummer %d</string>
|
||||
|
||||
<string name="desc_play_pause">Afspelen/Pauzeren</string>
|
||||
|
||||
@@ -14,8 +14,8 @@
|
||||
|
||||
<dimen name="size_cover_compact">48dp</dimen>
|
||||
<dimen name="size_cover_normal">56dp</dimen>
|
||||
<dimen name="size_cover_huge_land">136dp</dimen>
|
||||
<dimen name="size_cover_huge">264dp</dimen>
|
||||
<dimen name="size_cover_huge_land">128dp</dimen>
|
||||
<dimen name="size_cover_huge">256dp</dimen>
|
||||
|
||||
<dimen name="size_stroke_small">1dp</dimen>
|
||||
<dimen name="size_stroke_large">2dp</dimen>
|
||||
|
||||
@@ -4,8 +4,8 @@
|
||||
<string name="info_app_name" translatable="false">Auxio</string>
|
||||
|
||||
<!-- Format Namespace | Value formatting/plurals -->
|
||||
<string name="format_info" translatable="false">%1$s • %2$s</string>
|
||||
<string name="format_double_info" translatable="false">%1$s • %2$s • %3$s</string>
|
||||
<string name="format_double_counts" translatable="false">%1$s, %2$s</string>
|
||||
<string name="format_accent_summary" translatable="false"><b>%1$s</b>: %2$s</string>
|
||||
<string name="fmt_two" translatable="false">%1$s • %2$s</string>
|
||||
<string name="fmt_three" translatable="false">%1$s • %2$s • %3$s</string>
|
||||
<string name="fmt_counts" translatable="false">%1$s, %2$s</string>
|
||||
<string name="fmt_accent_desc" translatable="false"><b>%1$s</b>: %2$s</string>
|
||||
</resources>
|
||||
@@ -114,7 +114,6 @@
|
||||
<string name="hint_search_library">Search your library…</string>
|
||||
|
||||
<!-- Description Namespace | Accessibility Strings -->
|
||||
<string name="desc_sort_button">Change Sort Order</string>
|
||||
<string name="desc_track_number">Track %d</string>
|
||||
|
||||
<string name="desc_play_pause">Play or Pause</string>
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
<style name="Theme.Base" parent="Theme.Splash">
|
||||
<!-- Colors -->
|
||||
<item name="colorSurface">@color/surface</item>
|
||||
<item name="colorAccent">@color/design_default_color_primary</item>
|
||||
<item name="colorAccent">@color/blue</item>
|
||||
|
||||
<item name="colorPrimary">?attr/colorAccent</item>
|
||||
<item name="colorOnPrimary">?attr/colorSurface</item>
|
||||
|
||||
@@ -197,26 +197,24 @@
|
||||
<item name="android:background">@drawable/ui_small_unbounded_ripple</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Button.Vibrant.Base" parent="@style/Widget.MaterialComponents.Button.TextButton">
|
||||
<style name="Widget.Button.Vibrant.Primary" parent="@style/Widget.MaterialComponents.Button.TextButton">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:clickable">true</item>
|
||||
<item name="android:focusable">true</item>
|
||||
<item name="fontFamily">@font/inter_semibold</item>
|
||||
<item name="android:letterSpacing">0.05</item>
|
||||
<item name="android:textAllCaps">false</item>
|
||||
<item name="android:textSize">@dimen/text_size_small</item>
|
||||
<item name="textAllCaps">false</item>
|
||||
<item name="android:textColor">?attr/colorSurface</item>
|
||||
<item name="fontFamily">@font/inter_semibold</item>
|
||||
<item name="cornerRadius">0dp</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Button.Vibrant.Primary" parent="@style/Widget.Button.Vibrant.Base">
|
||||
<item name="android:textColor">?attr/colorSurface</item>
|
||||
<item name="backgroundTint">?attr/colorAccent</item>
|
||||
<item name="rippleColor">@color/mtrl_btn_ripple_color</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Button.Vibrant.Secondary" parent="@style/Widget.Button.Vibrant.Base">
|
||||
<item name="strokeColor">@color/overlay_divider</item>
|
||||
<item name="strokeWidth">@dimen/size_stroke_small</item>
|
||||
<item name="rippleColor">?attr/colorControlHighlight</item>
|
||||
<style name="Widget.Button.Vibrant.Secondary" parent="@style/Widget.MaterialComponents.Button.OutlinedButton">
|
||||
<item name="android:layout_width">0dp</item>
|
||||
<item name="android:layout_height">wrap_content</item>
|
||||
<item name="android:letterSpacing">0.05</item>
|
||||
<item name="android:textAllCaps">false</item>
|
||||
<item name="android:textSize">@dimen/text_size_small</item>
|
||||
<item name="fontFamily">@font/inter_semibold</item>
|
||||
<item name="cornerRadius">0dp</item>
|
||||
</style>
|
||||
</resources>
|
||||
Reference in New Issue
Block a user