aboutsummaryrefslogtreecommitdiff
path: root/subsonic-android
diff options
context:
space:
mode:
Diffstat (limited to 'subsonic-android')
-rw-r--r--subsonic-android/res/menu/nowplaying_context.xml5
-rw-r--r--subsonic-android/res/values/strings.xml1
-rw-r--r--subsonic-android/src/github/daneren2005/subphonic/activity/DownloadActivity.java8
3 files changed, 14 insertions, 0 deletions
diff --git a/subsonic-android/res/menu/nowplaying_context.xml b/subsonic-android/res/menu/nowplaying_context.xml
index 16fb47d7..04e56e1a 100644
--- a/subsonic-android/res/menu/nowplaying_context.xml
+++ b/subsonic-android/res/menu/nowplaying_context.xml
@@ -15,6 +15,11 @@
android:id="@+id/menu_remove"
android:title="@string/download.menu_remove"
/>
+
+ <item
+ android:id="@+id/menu_delete"
+ android:title="@string/download.menu_delete"
+ />
<item
android:id="@+id/menu_remove_all"
diff --git a/subsonic-android/res/values/strings.xml b/subsonic-android/res/values/strings.xml
index 2431bb34..9a10b0ec 100644
--- a/subsonic-android/res/values/strings.xml
+++ b/subsonic-android/res/values/strings.xml
@@ -86,6 +86,7 @@
<string name="download.menu_show_album">Show album</string>
<string name="download.menu_lyrics">Lyrics</string>
<string name="download.menu_remove">Remove song</string>
+ <string name="download.menu_delete">Delete song</string>
<string name="download.menu_remove_all">Remove all</string>
<string name="download.menu_screen_on">Screen on</string>
<string name="download.menu_screen_off">Screen off</string>
diff --git a/subsonic-android/src/github/daneren2005/subphonic/activity/DownloadActivity.java b/subsonic-android/src/github/daneren2005/subphonic/activity/DownloadActivity.java
index 3c2d7b04..80c264f5 100644
--- a/subsonic-android/src/github/daneren2005/subphonic/activity/DownloadActivity.java
+++ b/subsonic-android/src/github/daneren2005/subphonic/activity/DownloadActivity.java
@@ -74,6 +74,7 @@ import github.daneren2005.subphonic.util.Util;
import github.daneren2005.subphonic.view.VisualizerView;
import static github.daneren2005.subphonic.domain.PlayerState.*;
+import java.util.ArrayList;
public class DownloadActivity extends SubsonicTabActivity implements OnGestureListener {
@@ -556,6 +557,13 @@ public class DownloadActivity extends SubsonicTabActivity implements OnGestureLi
getDownloadService().remove(song);
onDownloadListChanged();
return true;
+ case R.id.menu_delete:
+ getDownloadService().remove(song);
+ List<MusicDirectory.Entry> songs = new ArrayList<MusicDirectory.Entry>(1);
+ songs.add(song.getSong());
+ getDownloadService().delete(songs);
+ onDownloadListChanged();
+ return true;
case R.id.menu_remove_all:
getDownloadService().setShufflePlayEnabled(false);
getDownloadService().clear();