Add settings to pin and unpin playlist in toolbar menu

This commit is contained in:
CappielloAntonio 2021-11-25 22:48:21 +01:00
parent afe0e0751c
commit e29b96d905
11 changed files with 170 additions and 5 deletions

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@color/titleTextColor"
android:pathData="M16,9V4l1,0c0.55,0 1,-0.45 1,-1v0c0,-0.55 -0.45,-1 -1,-1H7C6.45,2 6,2.45 6,3v0c0,0.55 0.45,1 1,1l1,0v5c0,1.66 -1.34,3 -3,3h0v2h5.97v7l1,1l1,-1v-7H19v-2h0C17.34,12 16,10.66 16,9z"
android:fillType="evenOdd"/>
</vector>

View file

@ -0,0 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@color/titleTextColor"
android:pathData="M14,4v5c0,1.12 0.37,2.16 1,3H9c0.65,-0.86 1,-1.9 1,-3V4H14M17,2H7C6.45,2 6,2.45 6,3c0,0.55 0.45,1 1,1c0,0 0,0 0,0l1,0v5c0,1.66 -1.34,3 -3,3v2h5.97v7l1,1l1,-1v-7H19v-2c0,0 0,0 0,0c-1.66,0 -3,-1.34 -3,-3V4l1,0c0,0 0,0 0,0c0.55,0 1,-0.45 1,-1C18,2.45 17.55,2 17,2L17,2z"/>
</vector>

View file

@ -7,4 +7,16 @@
android:iconTint="@color/titleTextColor"
android:title="@string/menu_download_all_button"
app:showAsAction="never" />
<item
android:id="@+id/action_pin_playlist"
android:icon="@drawable/ic_pin_in"
android:iconTint="@color/titleTextColor"
android:title="@string/menu_pin_button"
app:showAsAction="never" />
<item
android:id="@+id/action_unpin_playlist"
android:icon="@drawable/ic_pin_out"
android:iconTint="@color/titleTextColor"
android:title="@string/menu_unpin_button"
app:showAsAction="never" />
</menu>

View file

@ -105,8 +105,10 @@
<string name="menu_download_label">Download</string>
<string name="menu_home_label">Home</string>
<string name="menu_library_label">Library</string>
<string name="menu_pin_button">Pin</string>
<string name="menu_search_button">Search</string>
<string name="menu_settings_button">Settings</string>
<string name="menu_unpin_button">Unpin</string>
<string name="player_bottom_sheet_title">Now playing</string>
<string name="playing_notification_description">The playing notification provides actions for play/pause etc.</string>
<string name="playing_notification_name">Playing Notification</string>