From f451bdbfa4450ff8fb5afc5bdc1555a6b5f41032 Mon Sep 17 00:00:00 2001 From: Nathan Schulzke Date: Tue, 27 Jul 2021 13:26:51 -0600 Subject: [PATCH] Do not add Mark as Watched to a live stream. --- .../org/schabi/newpipe/local/feed/FeedFragment.kt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/local/feed/FeedFragment.kt b/app/src/main/java/org/schabi/newpipe/local/feed/FeedFragment.kt index 85fea2efe..815418895 100644 --- a/app/src/main/java/org/schabi/newpipe/local/feed/FeedFragment.kt +++ b/app/src/main/java/org/schabi/newpipe/local/feed/FeedFragment.kt @@ -331,8 +331,7 @@ class FeedFragment : BaseStateFragment() { StreamDialogEntry.start_here_on_background, StreamDialogEntry.append_playlist, StreamDialogEntry.share, - StreamDialogEntry.open_in_browser, - StreamDialogEntry.mark_as_watched + StreamDialogEntry.open_in_browser ) ) } else { @@ -342,11 +341,15 @@ class FeedFragment : BaseStateFragment() { StreamDialogEntry.start_here_on_popup, StreamDialogEntry.append_playlist, StreamDialogEntry.share, - StreamDialogEntry.open_in_browser, - StreamDialogEntry.mark_as_watched + StreamDialogEntry.open_in_browser ) ) } + if (item.streamType != StreamType.AUDIO_LIVE_STREAM && item.streamType != StreamType.LIVE_STREAM) { + entries.add( + StreamDialogEntry.mark_as_watched + ) + } StreamDialogEntry.setEnabledEntries(entries) InfoItemDialog(activity, item, StreamDialogEntry.getCommands(context)) { _, which ->