diff options
author | Scott Jackson <daneren2005@gmail.com> | 2013-11-29 12:58:48 -0800 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2013-11-29 12:58:48 -0800 |
commit | 14542ac3d39435011384cef3ffd5c61fa8af8c34 (patch) | |
tree | 3de3a885e9749af1578eb162498331ae20cdeae6 /src/github/daneren2005 | |
parent | 2430bf529f1209bbe5144658cee1b9e136311215 (diff) | |
download | dsub-14542ac3d39435011384cef3ffd5c61fa8af8c34.tar.gz dsub-14542ac3d39435011384cef3ffd5c61fa8af8c34.tar.bz2 dsub-14542ac3d39435011384cef3ffd5c61fa8af8c34.zip |
Added play next to other menus
Diffstat (limited to 'src/github/daneren2005')
-rw-r--r-- | src/github/daneren2005/dsub/fragments/SubsonicFragment.java | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/github/daneren2005/dsub/fragments/SubsonicFragment.java b/src/github/daneren2005/dsub/fragments/SubsonicFragment.java index bec0be05..d8de9982 100644 --- a/src/github/daneren2005/dsub/fragments/SubsonicFragment.java +++ b/src/github/daneren2005/dsub/fragments/SubsonicFragment.java @@ -216,6 +216,9 @@ public class SubsonicFragment extends Fragment { case R.id.artist_menu_play_shuffled:
downloadRecursively(artist.getId(), false, false, true, true, false);
break;
+ case R.id.artist_menu_play_next:
+ downloadRecursively(artist.getId(), false, true, false, false, false, true);
+ break;
case R.id.artist_menu_play_last:
downloadRecursively(artist.getId(), false, true, false, false, false);
break;
@@ -237,6 +240,9 @@ public class SubsonicFragment extends Fragment { case R.id.album_menu_play_shuffled:
downloadRecursively(entry.getId(), false, false, true, true, false);
break;
+ case R.id.album_menu_play_next:
+ downloadRecursively(entry.getId(), false, true, false, false, false, true);
+ break;
case R.id.album_menu_play_last:
downloadRecursively(entry.getId(), false, true, false, false, false);
break;
@@ -607,10 +613,16 @@ public class SubsonicFragment extends Fragment { protected void downloadRecursively(final String id, final boolean save, final boolean append, final boolean autoplay, final boolean shuffle, final boolean background) {
downloadRecursively(id, "", true, save, append, autoplay, shuffle, background);
}
+ protected void downloadRecursively(final String id, final boolean save, final boolean append, final boolean autoplay, final boolean shuffle, final boolean background, final boolean playNext) {
+ downloadRecursively(id, "", true, save, append, autoplay, shuffle, background, playNext);
+ }
protected void downloadPlaylist(final String id, final String name, final boolean save, final boolean append, final boolean autoplay, final boolean shuffle, final boolean background) {
downloadRecursively(id, name, false, save, append, autoplay, shuffle, background);
}
protected void downloadRecursively(final String id, final String name, final boolean isDirectory, final boolean save, final boolean append, final boolean autoplay, final boolean shuffle, final boolean background) {
+ downloadRecursively(id, name, isDirectory, save, append, autoplay, shuffle, background, false);
+ }
+ protected void downloadRecursively(final String id, final String name, final boolean isDirectory, final boolean save, final boolean append, final boolean autoplay, final boolean shuffle, final boolean background, final boolean playNext) {
LoadingTask<List<MusicDirectory.Entry>> task = new LoadingTask<List<MusicDirectory.Entry>>(context) {
private static final int MAX_SONGS = 500;
@@ -652,7 +664,7 @@ public class SubsonicFragment extends Fragment { }
warnIfNetworkOrStorageUnavailable();
if(!background) {
- downloadService.download(songs, save, autoplay, false, shuffle);
+ downloadService.download(songs, save, autoplay, playNext, shuffle);
if(!append) {
Util.startActivityWithoutTransition(context, DownloadActivity.class);
}
|