libsaria: Create a static playlist for the library

Signed-off-by: Bryan Schumaker <bjschuma@gmail.com>
This commit is contained in:
Bryan Schumaker 2012-03-18 14:45:29 -04:00
parent dfb5c09260
commit 29cb7f7a47
3 changed files with 8 additions and 5 deletions

View File

@ -10,7 +10,7 @@ using namespace std;
enum PlaylistFlags {
PL_NONE = (0),
PL_DRAIN = (1 << 0),
PL_NO_DRAIN = (1 << 0),
PL_STATIC = (1 << 1),
};
@ -22,6 +22,7 @@ namespace libsaria
class Playlist {
private:
unsigned int flags;
/*bool del_renderer;
unsigned int flags;
string filename;

View File

@ -1,4 +1,5 @@
// Copyright (c) 2011 Bryan Schumaker.
#include <libsaria/playlist.h>
#include <libsaria/library.h>
#include <libsaria/track.h>
#include "library.h"
@ -15,6 +16,7 @@ using namespace std;
static list<struct libsaria::library::Path> path_list;
list<libsaria::library::Driver *> driver_list;
libsaria::Playlist lib_playlist(PL_STATIC | PL_NO_DRAIN);
/*list<libsaria::LibraryPath> path_list;
libsaria::Playlist lib_playlist(PL_RANDOM | PL_SEQUENTIAL | PL_FILTER);
static map<sid_t, libsaria::Track *> lookup_map;

View File

@ -38,18 +38,18 @@ namespace libsaria
Playlist::Playlist(string file, unsigned int options)
{
init_common(file, options);
}
}*/
Playlist::Playlist(unsigned int options)
Playlist::Playlist(unsigned int f)
{
init_common("", options);
flags = f;
}
Playlist::~Playlist()
{
}
void Playlist::set_renderer(PlaylistRenderer *render, bool del_render)
/*void Playlist::set_renderer(PlaylistRenderer *render, bool del_render)
{
renderer = render;
del_renderer = del_render;