music: add playlist addition
Implement playlist addition and it's UI flow.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- TODO: Rename picker usages to choice usages now that the former is used more generally -->
|
||||
<org.oxycblt.auxio.list.recycler.DialogRecyclerView 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"
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<androidx.constraintlayout.widget.ConstraintLayout 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"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/selectableItemBackground"
|
||||
android:paddingStart="@dimen/spacing_large"
|
||||
android:paddingTop="@dimen/spacing_mid_medium"
|
||||
android:paddingEnd="@dimen/spacing_large"
|
||||
android:paddingBottom="@dimen/spacing_mid_medium">
|
||||
|
||||
<org.oxycblt.auxio.image.ImageGroup
|
||||
android:id="@+id/picker_image"
|
||||
style="@style/Widget.Auxio.Image.Small"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:staticIcon="@drawable/ic_add_24" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/picker_name"
|
||||
style="@style/Widget.Auxio.TextView.Item.Primary"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginEnd="@dimen/spacing_mid_medium"
|
||||
android:textColor="@color/sel_selectable_text_primary"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toEndOf="@+id/picker_image"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintVertical_chainStyle="packed"
|
||||
android:text="@string/lbl_new_playlist" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -15,4 +15,7 @@
|
||||
<item
|
||||
android:id="@+id/action_go_artist"
|
||||
android:title="@string/lbl_go_artist" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
</menu>
|
||||
@@ -9,6 +9,9 @@
|
||||
<item
|
||||
android:id="@+id/action_go_artist"
|
||||
android:title="@string/lbl_go_artist" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
<item
|
||||
android:id="@+id/action_song_detail"
|
||||
android:title="@string/lbl_song_detail" />
|
||||
|
||||
@@ -15,4 +15,7 @@
|
||||
<item
|
||||
android:id="@+id/action_queue_add"
|
||||
android:title="@string/lbl_queue_add" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
</menu>
|
||||
@@ -9,6 +9,9 @@
|
||||
<item
|
||||
android:id="@+id/action_go_album"
|
||||
android:title="@string/lbl_go_album" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
<item
|
||||
android:id="@+id/action_song_detail"
|
||||
android:title="@string/lbl_song_detail" />
|
||||
|
||||
@@ -12,4 +12,7 @@
|
||||
<item
|
||||
android:id="@+id/action_queue_add"
|
||||
android:title="@string/lbl_queue_add" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
</menu>
|
||||
@@ -6,4 +6,7 @@
|
||||
<item
|
||||
android:id="@+id/action_queue_add"
|
||||
android:title="@string/lbl_queue_add" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
</menu>
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item
|
||||
android:id="@+id/action_play"
|
||||
android:title="@string/lbl_play" />
|
||||
<item
|
||||
android:id="@+id/action_shuffle"
|
||||
android:title="@string/lbl_shuffle" />
|
||||
<item
|
||||
android:id="@+id/action_play_next"
|
||||
android:title="@string/lbl_play_next" />
|
||||
<item
|
||||
android:id="@+id/action_queue_add"
|
||||
android:title="@string/lbl_queue_add" />
|
||||
</menu>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item
|
||||
android:id="@+id/action_play_next"
|
||||
android:title="@string/lbl_play_next" />
|
||||
<item
|
||||
android:id="@+id/action_queue_add"
|
||||
android:title="@string/lbl_queue_add" />
|
||||
</menu>
|
||||
@@ -10,6 +10,9 @@
|
||||
android:id="@+id/action_selection_queue_add"
|
||||
android:title="@string/lbl_queue_add"
|
||||
app:showAsAction="never" />
|
||||
<item
|
||||
android:id="@+id/action_selection_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
<item
|
||||
android:id="@+id/action_selection_play"
|
||||
android:title="@string/lbl_play_selected"
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
<item
|
||||
android:id="@+id/action_go_album"
|
||||
android:title="@string/lbl_go_album" />
|
||||
<item
|
||||
android:id="@+id/action_playlist_add"
|
||||
android:title="@string/lbl_playlist_add" />
|
||||
<item
|
||||
android:id="@+id/action_song_detail"
|
||||
android:title="@string/lbl_song_detail" />
|
||||
|
||||
@@ -20,6 +20,9 @@
|
||||
<action
|
||||
android:id="@+id/action_new_playlist"
|
||||
app:destination="@id/new_playlist_dialog" />
|
||||
<action
|
||||
android:id="@+id/action_add_to_playlist"
|
||||
app:destination="@id/add_to_playlist_dialog" />
|
||||
<action
|
||||
android:id="@+id/action_pick_navigation_artist"
|
||||
app:destination="@id/navigate_to_artist_dialog" />
|
||||
@@ -51,6 +54,19 @@
|
||||
app:argType="org.oxycblt.auxio.music.Music$UID[]" />
|
||||
</dialog>
|
||||
|
||||
<dialog
|
||||
android:id="@+id/add_to_playlist_dialog"
|
||||
android:name="org.oxycblt.auxio.music.picker.AddToPlaylistDialog"
|
||||
android:label="new_playlist_dialog"
|
||||
tools:layout="@layout/dialog_playlist_name">
|
||||
<argument
|
||||
android:name="songUids"
|
||||
app:argType="org.oxycblt.auxio.music.Music$UID[]" />
|
||||
<action
|
||||
android:id="@+id/action_new_playlist"
|
||||
app:destination="@id/new_playlist_dialog" />
|
||||
</dialog>
|
||||
|
||||
<dialog
|
||||
android:id="@+id/navigate_to_artist_dialog"
|
||||
android:name="org.oxycblt.auxio.navigation.picker.NavigateToArtistDialog"
|
||||
@@ -155,12 +171,12 @@
|
||||
tools:layout="@layout/dialog_pre_amp" />
|
||||
<dialog
|
||||
android:id="@+id/music_dirs_dialog"
|
||||
android:name="org.oxycblt.auxio.music.config.MusicDirsDialog"
|
||||
android:name="org.oxycblt.auxio.music.fs.MusicDirsDialog"
|
||||
android:label="music_dirs_dialog"
|
||||
tools:layout="@layout/dialog_music_dirs" />
|
||||
<dialog
|
||||
android:id="@+id/separators_dialog"
|
||||
android:name="org.oxycblt.auxio.music.config.SeparatorsDialog"
|
||||
android:name="org.oxycblt.auxio.music.metadata.SeparatorsDialog"
|
||||
android:label="music_dirs_dialog"
|
||||
tools:layout="@layout/dialog_separators" />
|
||||
|
||||
|
||||
@@ -111,6 +111,8 @@
|
||||
<string name="lbl_play_next">Play next</string>
|
||||
<string name="lbl_queue_add">Add to queue</string>
|
||||
|
||||
<string name="lbl_playlist_add">Add to playlist</string>
|
||||
|
||||
<string name="lbl_go_artist">Go to artist</string>
|
||||
<string name="lbl_go_album">Go to album</string>
|
||||
<string name="lbl_song_detail">View properties</string>
|
||||
@@ -160,6 +162,8 @@
|
||||
<string name="lng_indexing">Loading your music library…</string>
|
||||
<string name="lng_observing">Monitoring your music library for changes…</string>
|
||||
<string name="lng_queue_added">Added to queue</string>
|
||||
<string name="lng_playlist_created">Playlist created</string>
|
||||
<string name="lng_playlist_added">Added to playlist</string>
|
||||
<string name="lng_author">Developed by Alexander Capehart</string>
|
||||
<!-- As in music library -->
|
||||
<string name="lng_search_library">Search your library…</string>
|
||||
|
||||
Reference in New Issue
Block a user