aboutsummaryrefslogtreecommitdiffstats
path: root/src/directory.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2012-02-12 17:50:30 +0100
committerMax Kellermann <max@duempel.org>2012-02-12 17:50:30 +0100
commitac3ad452c03292e4c57b0d0e21c2dd407eb03a27 (patch)
tree10e12f06f7a62a0cab6eb0bf06a4e8a09e2d0d78 /src/directory.h
parent027c01511cfb8eac1a2e3f9fc54cfbb2bf968870 (diff)
downloadmpd-ac3ad452c03292e4c57b0d0e21c2dd407eb03a27.tar.gz
mpd-ac3ad452c03292e4c57b0d0e21c2dd407eb03a27.tar.xz
mpd-ac3ad452c03292e4c57b0d0e21c2dd407eb03a27.zip
playlist_vector: use the list_head library
Diffstat (limited to 'src/directory.h')
-rw-r--r--src/directory.h11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/directory.h b/src/directory.h
index 769260436..dc664a433 100644
--- a/src/directory.h
+++ b/src/directory.h
@@ -22,7 +22,6 @@
#include "check.h"
#include "util/list.h"
-#include "playlist_vector.h"
#include <glib.h>
#include <stdbool.h>
@@ -45,6 +44,12 @@
#define directory_for_each_song_safe(pos, n, directory) \
list_for_each_entry_safe(pos, n, &directory->songs, siblings)
+#define directory_for_each_playlist(pos, directory) \
+ list_for_each_entry(pos, &directory->playlists, siblings)
+
+#define directory_for_each_playlist_safe(pos, n, directory) \
+ list_for_each_entry_safe(pos, n, &directory->playlists, siblings)
+
struct song;
struct db_visitor;
@@ -75,7 +80,7 @@ struct directory {
*/
struct list_head songs;
- struct playlist_vector playlists;
+ struct list_head playlists;
struct directory *parent;
time_t mtime;
@@ -129,7 +134,7 @@ directory_is_empty(const struct directory *directory)
{
return list_empty(&directory->children) &&
list_empty(&directory->songs) &&
- playlist_vector_is_empty(&directory->playlists);
+ list_empty(&directory->playlists);
}
static inline const char *