diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2015-01-19 21:54:19 +0100 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2015-01-19 21:54:19 +0100 |
commit | efcbbfe2b93182dbb8458fdf049816b8710ba8af (patch) | |
tree | dbeeddff8667424bbc7822ee02f9cbdae46ca30c /core/src/main | |
parent | d04aa8295426f786e9fa75f74038f170060d823d (diff) | |
parent | 7f02e1b1875d2fa3391308a57def055b95d76c3d (diff) | |
download | AntennaPod-efcbbfe2b93182dbb8458fdf049816b8710ba8af.zip |
Merge branch 'SamWhited-delete-episode-update' into develop
Diffstat (limited to 'core/src/main')
-rw-r--r-- | core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackService.java | 9 | ||||
-rw-r--r-- | core/src/main/res/values/strings.xml | 2 |
2 files changed, 11 insertions, 0 deletions
diff --git a/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackService.java b/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackService.java index 866f1cba3..aabbcc185 100644 --- a/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackService.java +++ b/core/src/main/java/de/danoeh/antennapod/core/service/playback/PlaybackService.java @@ -553,6 +553,15 @@ public class PlaybackService extends Service { if (isAutoFlattrable(media) && UserPreferences.getAutoFlattrPlayedDurationThreshold() == 1.0f) { DBTasks.flattrItemIfLoggedIn(PlaybackService.this, item); } + + //Delete episode if enabled + if(UserPreferences.isAutoDelete()) { + DBWriter.deleteFeedMediaOfItem(PlaybackService.this, item.getMedia().getId()); + + if(BuildConfig.DEBUG) + Log.d(TAG, "Episode Deleted"); + } + } // Load next episode if previous episode was in the queue and if there diff --git a/core/src/main/res/values/strings.xml b/core/src/main/res/values/strings.xml index dcad6c201..130007016 100644 --- a/core/src/main/res/values/strings.xml +++ b/core/src/main/res/values/strings.xml @@ -207,6 +207,8 @@ <string name="pref_pauseOnHeadsetDisconnect_sum">Pause playback when the headphones are disconnected</string> <string name="pref_unpauseOnHeadsetReconnect_sum">Resume playback when the headphones are reconnected</string> <string name="pref_followQueue_sum">Jump to next queue item when playback completes</string> + <string name="pref_auto_delete_sum">Delete episode when playback completes</string> + <string name="pref_auto_delete_title">Auto Delete</string> <string name="playback_pref">Playback</string> <string name="network_pref">Network</string> <string name="pref_autoUpdateIntervall_title">Update interval</string> |