From 023f6166abf7e566662ccf88e5f11164cc838a3e Mon Sep 17 00:00:00 2001 From: AudricV <74829229+AudricV@users.noreply.github.com> Date: Tue, 2 May 2023 00:18:46 +0200 Subject: [PATCH] Add Open in browser button to audio external players dialog This change makes the dialog consistent with the video one. --- .../schabi/newpipe/fragments/detail/VideoDetailFragment.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java b/app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java index d8b2b43a5..8227f1c69 100644 --- a/app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java +++ b/app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java @@ -2166,12 +2166,13 @@ public final class VideoDetailFragment if (audioTracks.isEmpty()) { Toast.makeText(activity, R.string.no_audio_streams_available_for_external_players, Toast.LENGTH_SHORT).show(); - } else if (audioTracks.size() == 1) { startOnExternalPlayer(activity, currentInfo, audioTracks.get(0)); } else { final AlertDialog.Builder builder = new AlertDialog.Builder(activity); builder.setTitle(R.string.select_audio_track_external_players); + builder.setNeutralButton(R.string.open_in_browser, (dialog, i) -> + ShareUtils.openUrlInBrowser(requireActivity(), url)); final int selectedAudioStream = ListHelper.getDefaultAudioFormat(activity, audioTracks);