diff options
Diffstat (limited to 'app/src/main/java/de/danoeh/antennapod/adapter')
-rw-r--r-- | app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java b/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java index 117ba3258..0e238eae2 100644 --- a/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java +++ b/app/src/main/java/de/danoeh/antennapod/adapter/QueueRecyclerAdapter.java @@ -44,7 +44,7 @@ public class QueueRecyclerAdapter extends EpisodeItemListAdapter { return false; }; - if (!dragDropEnabled) { + if (!dragDropEnabled || inActionMode()) { holder.dragHandle.setVisibility(View.GONE); holder.dragHandle.setOnTouchListener(null); holder.coverHolder.setOnTouchListener(null); @@ -63,11 +63,17 @@ public class QueueRecyclerAdapter extends EpisodeItemListAdapter { inflater.inflate(R.menu.queue_context, menu); super.onCreateContextMenu(menu, v, menuInfo); - final boolean keepSorted = UserPreferences.isQueueKeepSorted(); - if (getItem(0).getId() == getLongPressedItem().getId() || keepSorted) { + if (!inActionMode()) { + menu.findItem(R.id.multi_select).setVisible(true); + final boolean keepSorted = UserPreferences.isQueueKeepSorted(); + if (getItem(0).getId() == getLongPressedItem().getId() || keepSorted) { + menu.findItem(R.id.move_to_top_item).setVisible(false); + } + if (getItem(getItemCount() - 1).getId() == getLongPressedItem().getId() || keepSorted) { + menu.findItem(R.id.move_to_bottom_item).setVisible(false); + } + } else { menu.findItem(R.id.move_to_top_item).setVisible(false); - } - if (getItem(getItemCount() - 1).getId() == getLongPressedItem().getId() || keepSorted) { menu.findItem(R.id.move_to_bottom_item).setVisible(false); } } |