Back to project page EnklawaPlayer.
The source code is released under:
GNU General Public License
If you think the Android project EnklawaPlayer listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package macbury.pod.fragments.main.episodes; //from w w w . j av a 2 s . co m import java.util.ArrayList; import java.util.List; import macbury.pod.adapters.EpisodesAdapter; import macbury.pod.db.models.EnqueueEpisode; import macbury.pod.db.models.Episode; import macbury.pod.fragments.main.AbstractEpisodesFragment; import macbury.pod.managers.App; /** * Created by macbury on 23.09.14. */ public class PlaylistFragment extends AbstractEpisodesFragment { @Override public void onResume() { super.onResume(); episodeAdapter.setMode(EpisodesAdapter.ActionMode.Trash); } @Override public List<Episode> getEpisodes() { ArrayList<Episode> episodes = new ArrayList<Episode>(); for(EnqueueEpisode item : app.db.queue.pendingToPlay()) { episodes.add(item.episode); } return episodes; } @Override public void onRemoveEpisodeButtonClick(Episode episode) { super.onRemoveEpisodeButtonClick(episode); App.current().db.queue.deleteByEpisode(episode); updateEpisodes(); } }