menu.add(GROUP_ID, FragmentMenuItems.PLAY_NEXT, Menu.NONE,
getString(R.string.context_menu_play_next));
- // Add the song to the queue
- menu.add(GROUP_ID, FragmentMenuItems.ADD_TO_QUEUE, Menu.NONE,
- getString(R.string.add_to_queue));
-
// Add the song to a playlist
final SubMenu subMenu = menu.addSubMenu(GROUP_ID, FragmentMenuItems.ADD_TO_PLAYLIST,
Menu.NONE, R.string.add_to_playlist);
MusicUtils.makePlaylistMenu(getActivity(), GROUP_ID, subMenu, true);
+ // Remove the song from the queue
+ menu.add(GROUP_ID, FragmentMenuItems.REMOVE_FROM_QUEUE, Menu.NONE,
+ getString(R.string.remove_from_queue));
+
// View more content by the song artist
menu.add(GROUP_ID, FragmentMenuItems.MORE_BY_ARTIST, Menu.NONE,
getString(R.string.context_menu_more_by_artist));
MusicUtils.playNext(new long[] {
mSelectedId
});
- getLoaderManager().restartLoader(LOADER, null, this);
+ refreshQueue();
return true;
- case FragmentMenuItems.ADD_TO_QUEUE:
- MusicUtils.addToQueue(getActivity(), new long[] {
- mSelectedId
- });
+ case FragmentMenuItems.REMOVE_FROM_QUEUE:
+ MusicUtils.removeTrack(mSelectedId);
+ refreshQueue();
return true;
case FragmentMenuItems.ADD_TO_FAVORITES:
FavoritesStore.getInstance(getActivity()).addSongId(