Fix playlist playback

Use the right column
This commit is contained in:
Christopher Eby 2010-05-23 11:24:23 -05:00
parent 0e8fb9cb29
commit c90934c1a1

View File

@ -101,7 +101,6 @@ public class MediaUtils {
*/ */
public static long[] getAllSongIdsWith(int type, long id) public static long[] getAllSongIdsWith(int type, long id)
{ {
String[] projection = { MediaStore.Audio.Media._ID };
Cursor cursor; Cursor cursor;
switch (type) { switch (type) {
@ -109,10 +108,10 @@ public class MediaUtils {
return new long[] { id }; return new long[] { id };
case TYPE_ARTIST: case TYPE_ARTIST:
case TYPE_ALBUM: case TYPE_ALBUM:
cursor = getMediaCursor(type, id, projection); cursor = getMediaCursor(type, id, new String[] { MediaStore.Audio.Media._ID });
break; break;
case TYPE_PLAYLIST: case TYPE_PLAYLIST:
cursor = getPlaylistCursor(id, projection); cursor = getPlaylistCursor(id, new String[] { MediaStore.Audio.Playlists.Members.AUDIO_ID });
break; break;
default: default:
throw new IllegalArgumentException("Specified type not valid: " + type); throw new IllegalArgumentException("Specified type not valid: " + type);