class playlist_loader_spl_xspf : public playlist_loader {
virtual void open(const char* p_path, const service_ptr_t<file>& p_file, playlist_loader_callback& p_callback) {
pfc::list_t<metadb_handle_ptr> tracks;
...
}
}
How should I return the playlist in the open() function knowing that the metadb_handle_ptr's of the playlist traks are in the variable tracks?
By calling various methods of [font= "Courier New"]p_callback[/font] during processing.
Hmm I think it is impossible to do what I want with the normal playlist_loader .
I want to load an xspf playlist, but it will only include track_title track_artist couples, so no paths to a filename. A pure soft playlist.
So I need access to the library. But I think that is not possble?
static_api_ptr_t<library_manager> lm;
lm->get_all_items(library);
This doesn't seem to work.
So is there a way around it, or will i have to make a special menu entry to load these type of playlists?
And if yes, is there a fucntion provided to display a file load dialog filtered by an extension?
static_api_ptr_t<library_manager> lm;
lm->get_all_items(library);
This doesn't seem to work.
How specifically?
And if yes, is there a fucntion provided to display a file load dialog filtered by an extension?
[font= "Courier New"]uGetOpenFileName()[/font].
From the SDK documentation for class library_manager (http://foosion.foobar2000.org/doxygen/latest/classlibrary__manager.html):
All methods are valid from main thread only, unless noted otherwise.
Thanks for the info, I've made separate menu entries for what I'm trying to do.