Support and General Use > Audio Playback, Database and Playlists
"Add To Playlist" patch
Shebb:
Been away for some time.
Well this is something I really would like to see implemented in Rockbox some day. Building up multiple playlists at a time is something I think is useful. I like to use it to gather up music that has been encoded poorly or I can't justify having on my player. The favorites plugin is a little too limiting for me.
I could recode it in a way that fits the rockbox design philosophy if you could tell me what I shouldn't be doing, Linus. The 'favorites' plugin just writes the information to the end. I thought it would be better to use the playlist API becuase functionality such as insert directory is already implented there.
LinusN:
The problem with the playlist API is that it is designed to be used on the running playlist. It can't be used on a disk-based list while another is playing.
That might be a bug in the playlist code, but that's how it works today at least.
Shebb:
That is not how it works for me. I can play my shuffled playlist of all my music and use 'Playlist catalog' to add the currently playing track to any playlist I have indexed. Whilst the music is still playing I can also browse through my files and add them to any indexed playlist. The playlist.h file states that the functions can be used for all playlists even if another is currently loaded. From this I infered that the playlist API was designed to be used on any playlist not just the current one.
There are parts of my code that I do not like, for instance much of the stuff that governs the saved playlists, but the actual playlist manipulation parts I believe are correct.
Shebb:
Well here is a new patch anyway... Using diff through cvs made a massive file for some reason which just replaced all the old file with my updated one. Drop the .doc extention and apply this to onplay.c in the apps folder.
[attachment deleted by admin, too old]
lenny:
Shebb thank you
it works great
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version