Make Queue nav destination
Fix a heisenleak by making QueueFragment a navigation destination instead of being directly instantiated.
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
|
||||
@@ -115,5 +115,14 @@
|
||||
android:id="@+id/playback_fragment"
|
||||
android:name="org.oxycblt.auxio.playback.PlaybackFragment"
|
||||
android:label="PlaybackFragment"
|
||||
tools:layout="@layout/fragment_playback" />
|
||||
tools:layout="@layout/fragment_playback" >
|
||||
<action
|
||||
android:id="@+id/action_show_queue"
|
||||
app:destination="@id/queue_fragment" />
|
||||
</fragment>
|
||||
<dialog
|
||||
android:id="@+id/queue_fragment"
|
||||
android:name="org.oxycblt.auxio.playback.queue.QueueFragment"
|
||||
android:label="QueueFragment"
|
||||
tools:layout="@layout/fragment_queue"/>
|
||||
</navigation>
|
||||
@@ -27,6 +27,7 @@
|
||||
<string name="label_play">Play</string>
|
||||
<string name="label_queue">Queue</string>
|
||||
<string name="label_queue_add">Add to queue</string>
|
||||
<string name="label_next_songs">Next from: All Songs</string>
|
||||
<string name="label_notification_playback">Music Playback</string>
|
||||
<string name="label_service_playback">The music playback service for Auxio.</string>
|
||||
|
||||
@@ -62,6 +63,7 @@
|
||||
<string name="format_info">%1$s / %2$s</string>
|
||||
<string name="format_double_info">%1$s / %2$s / %3$s</string>
|
||||
<string name="format_double_counts">%1$s, %2$s</string>
|
||||
<string name="format_next_from">Next From: %s</string>
|
||||
|
||||
<plurals name="format_song_count">
|
||||
<item quantity="one">%s Song</item>
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
</style>
|
||||
|
||||
<!--
|
||||
Hack to get QueueFragment to not overlap the Status Bar or Navigation Bar
|
||||
Fix to get QueueFragment to not overlap the Status Bar or Navigation Bar
|
||||
https://stackoverflow.com/a/57790787/14143986
|
||||
-->
|
||||
<style name="Theme.BottomSheetFix" parent="@style/Theme.Design.BottomSheetDialog">
|
||||
|
||||
Reference in New Issue
Block a user