diff options
author | Scott Jackson <daneren2005@gmail.com> | 2014-10-04 18:23:14 -0700 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2014-10-04 18:23:14 -0700 |
commit | be75b266a7c1d44b33b7cc93e39469f61c715999 (patch) | |
tree | 956e4cb4a0b1026c28fad1a282ee0ef16d1bd54a /src/github | |
parent | 51ffbb23b82287932089881c920203257022eedc (diff) | |
download | dsub-be75b266a7c1d44b33b7cc93e39469f61c715999.tar.gz dsub-be75b266a7c1d44b33b7cc93e39469f61c715999.tar.bz2 dsub-be75b266a7c1d44b33b7cc93e39469f61c715999.zip |
Add cache/delete to album only option menus
Diffstat (limited to 'src/github')
-rw-r--r-- | src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java b/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java index dce7d004..cb357976 100644 --- a/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java +++ b/src/github/daneren2005/dsub/fragments/SelectDirectoryFragment.java @@ -895,10 +895,11 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter private void downloadBackground(final boolean save) {
List<Entry> songs = getSelectedSongs();
if(songs.isEmpty()) {
- selectAll(true, false);
- songs = getSelectedSongs();
+ // Get both songs and albums
+ downloadRecursively(id, save, false, false, false, true);
+ } else {
+ downloadBackground(save, songs);
}
- downloadBackground(save, songs);
}
private void downloadBackground(final boolean save, final List<Entry> songs) {
if (getDownloadService() == null) {
@@ -927,6 +928,11 @@ public class SelectDirectoryFragment extends SubsonicFragment implements Adapter if(songs.isEmpty()) {
selectAll(true, false);
songs = getSelectedSongs();
+
+ // Also delete all directories
+ for(Entry album: albums) {
+ deleteRecursively(album);
+ }
}
if (getDownloadService() != null) {
getDownloadService().delete(songs);
|