diff options
author | Scott Jackson <daneren2005@gmail.com> | 2013-12-09 22:11:30 -0800 |
---|---|---|
committer | Scott Jackson <daneren2005@gmail.com> | 2013-12-09 22:11:30 -0800 |
commit | a0c2a21f81e2af5a03a51e1c25e99fcbe6b07839 (patch) | |
tree | 08811a6e66539b6b4c9a5759cdfc659da5e972df | |
parent | c87970da62b1dc2df2e97de99a06cb2242917622 (diff) | |
download | dsub-a0c2a21f81e2af5a03a51e1c25e99fcbe6b07839.tar.gz dsub-a0c2a21f81e2af5a03a51e1c25e99fcbe6b07839.tar.bz2 dsub-a0c2a21f81e2af5a03a51e1c25e99fcbe6b07839.zip |
Don't pin recently added syncs
-rw-r--r-- | src/github/daneren2005/dsub/service/sync/MostRecentSyncAdapter.java | 2 | ||||
-rw-r--r-- | src/github/daneren2005/dsub/service/sync/SubsonicSyncAdapter.java | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/github/daneren2005/dsub/service/sync/MostRecentSyncAdapter.java b/src/github/daneren2005/dsub/service/sync/MostRecentSyncAdapter.java index a12d789d..ef17cf5d 100644 --- a/src/github/daneren2005/dsub/service/sync/MostRecentSyncAdapter.java +++ b/src/github/daneren2005/dsub/service/sync/MostRecentSyncAdapter.java @@ -66,7 +66,7 @@ public class MostRecentSyncAdapter extends SubsonicSyncAdapter { for(MusicDirectory.Entry album: albumList.getChildren()) {
if(!syncedList.contains(album.getId())) {
try {
- downloadRecursively(musicService.getMusicDirectory(album.getId(), album.getTitle(), true, context, null), context);
+ downloadRecursively(musicService.getMusicDirectory(album.getId(), album.getTitle(), true, context, null), context, false);
syncedList.add(album.getId());
updated = true;
} catch(Exception e) {
diff --git a/src/github/daneren2005/dsub/service/sync/SubsonicSyncAdapter.java b/src/github/daneren2005/dsub/service/sync/SubsonicSyncAdapter.java index 6eb22be0..c8e050e1 100644 --- a/src/github/daneren2005/dsub/service/sync/SubsonicSyncAdapter.java +++ b/src/github/daneren2005/dsub/service/sync/SubsonicSyncAdapter.java @@ -117,18 +117,18 @@ public class SubsonicSyncAdapter extends AbstractThreadedSyncAdapter { } - protected void downloadRecursively(MusicDirectory parent, Context context) throws Exception { + protected void downloadRecursively(MusicDirectory parent, Context context, boolean save) throws Exception { for (MusicDirectory.Entry song: parent.getChildren(false, true)) { if (!song.isVideo()) { - DownloadFile file = new DownloadFile(context, song, true); - while(!file.isSaved() && !file.isFailedMax()) { + DownloadFile file = new DownloadFile(context, song, save); + while(!file.isCompleteFileAvailable() && !file.isFailedMax()) { file.downloadNow(); } } } for (MusicDirectory.Entry dir: parent.getChildren(true, false)) { - downloadRecursively(musicService.getMusicDirectory(dir.getId(), dir.getTitle(), true, context, null), context); + downloadRecursively(musicService.getMusicDirectory(dir.getId(), dir.getTitle(), true, context, null), context, save); } } } |