diff --git a/app/src/main/java/org/ntlab/amaryllis/client/voiceservice/PlayListManager.java b/app/src/main/java/org/ntlab/amaryllis/client/voiceservice/PlayListManager.java index e5e0edd..80a5faa 100644 --- a/app/src/main/java/org/ntlab/amaryllis/client/voiceservice/PlayListManager.java +++ b/app/src/main/java/org/ntlab/amaryllis/client/voiceservice/PlayListManager.java @@ -25,11 +25,19 @@ } //まだ聞いていないvoicememoのリスト public ArrayList getUnplayedList(){ - //毎回リストを返すのか? - unplayedlist.clear(); - for(int i = index; i < playlist.size(); i++){ - unplayedlist.add(playlist.get(i)); + unplayedlist.remove(0); + for(int i = 0;i < unplayedlist.size(); i++) { + boolean exist = false; + for(int j= index;j < playlist.size(); j++){ + if(playlist.get(j).getVid().equals(unplayedlist.get(i).getVid())) + exist = true; + } + if(exist = false) + playlist.add(unplayedlist.get(i)); } +// for(int i = index; i < playlist.size(); i++){ +// unplayedlist.add(playlist.get(i)); +// } return unplayedlist; }