diff options
author | Vishnu Sanal T <50027064+VishnuSanal@users.noreply.github.com> | 2023-01-01 19:59:23 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-01 15:29:23 +0100 |
commit | 88289d02ae2a402ec77723dd53da33e9cf4c7311 (patch) | |
tree | 998806d05abcb74bed8d56e74742aa3473783a0c /app/src/main/java/de/danoeh/antennapod/dialog | |
parent | 97889a46ed2f9e6e5fc6144b84f1c2367d311a05 (diff) | |
download | AntennaPod-88289d02ae2a402ec77723dd53da33e9cf4c7311.zip |
Possibility to remove a single episode from playback history (#6184)
Diffstat (limited to 'app/src/main/java/de/danoeh/antennapod/dialog')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java b/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java index a4ed7ac8c..02336949e 100644 --- a/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java +++ b/app/src/main/java/de/danoeh/antennapod/dialog/SwipeActionsDialog.java @@ -27,6 +27,7 @@ import de.danoeh.antennapod.fragment.AllEpisodesFragment; import de.danoeh.antennapod.fragment.CompletedDownloadsFragment; import de.danoeh.antennapod.fragment.FeedItemlistFragment; import de.danoeh.antennapod.fragment.InboxFragment; +import de.danoeh.antennapod.fragment.PlaybackHistoryFragment; import de.danoeh.antennapod.fragment.QueueFragment; import de.danoeh.antennapod.fragment.swipeactions.SwipeAction; import de.danoeh.antennapod.fragment.swipeactions.SwipeActions; @@ -62,22 +63,32 @@ public class SwipeActionsDialog { case InboxFragment.TAG: forFragment = context.getString(R.string.inbox_label); keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.TOGGLE_PLAYED) - && !a.getId().equals(SwipeAction.DELETE)).toList(); + && !a.getId().equals(SwipeAction.DELETE) + && !a.getId().equals(SwipeAction.REMOVE_FROM_HISTORY)).toList(); break; case AllEpisodesFragment.TAG: forFragment = context.getString(R.string.episodes_label); + keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.REMOVE_FROM_HISTORY)).toList(); break; case CompletedDownloadsFragment.TAG: forFragment = context.getString(R.string.downloads_label); - keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.REMOVE_FROM_INBOX)).toList(); + keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.REMOVE_FROM_INBOX) + && !a.getId().equals(SwipeAction.REMOVE_FROM_HISTORY) + && !a.getId().equals(SwipeAction.START_DOWNLOAD)).toList(); break; case FeedItemlistFragment.TAG: forFragment = context.getString(R.string.feeds_label); + keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.REMOVE_FROM_HISTORY)).toList(); break; case QueueFragment.TAG: forFragment = context.getString(R.string.queue_label); keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.ADD_TO_QUEUE) - && !a.getId().equals(SwipeAction.REMOVE_FROM_INBOX)).toList(); + && !a.getId().equals(SwipeAction.REMOVE_FROM_INBOX) + && !a.getId().equals(SwipeAction.REMOVE_FROM_HISTORY)).toList(); + break; + case PlaybackHistoryFragment.TAG: + forFragment = context.getString(R.string.playback_history_label); + keys = Stream.of(keys).filter(a -> !a.getId().equals(SwipeAction.REMOVE_FROM_INBOX)).toList(); break; default: break; } |