From 1b05c404d581c12c1cc217223ee0596b828475b5 Mon Sep 17 00:00:00 2001 From: ktprograms Date: Tue, 24 Aug 2021 19:15:53 +0800 Subject: [PATCH] Remove Details option in Main Player Queue menu --- app/src/main/java/org/schabi/newpipe/player/Player.java | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/player/Player.java b/app/src/main/java/org/schabi/newpipe/player/Player.java index 4c60df396..b24842a0e 100644 --- a/app/src/main/java/org/schabi/newpipe/player/Player.java +++ b/app/src/main/java/org/schabi/newpipe/player/Player.java @@ -3043,18 +3043,15 @@ public final class Player implements final PopupMenu popupMenu = new PopupMenu(themeWrapper, view); popupMenu.inflate(R.menu.menu_play_queue_item); + // Don't show Details in Main Player Popup + popupMenu.getMenu().findItem(R.id.menu_item_details).setVisible(false); + popupMenu.setOnMenuItemClickListener(menuItem -> { switch (menuItem.getItemId()) { case R.id.menu_item_remove: final int index = playQueue.indexOf(item); playQueue.remove(index); return true; - case R.id.menu_item_details: - // playQueue is null since we don't want any queue change - NavigationHelper.openVideoDetail(context, item.getServiceId(), - item.getUrl(), item.getTitle(), null, - false); - return true; case R.id.menu_item_append_playlist: final PlaylistAppendDialog d = PlaylistAppendDialog.fromPlayQueueItems( Collections.singletonList(item)