Directory: make the header C++ only

This commit is contained in:
Max Kellermann
2013-01-02 22:52:08 +01:00
parent d65ad1bf15
commit 0c245bc271
24 changed files with 33 additions and 53 deletions

View File

@@ -21,6 +21,7 @@
#include "DatabaseGlue.hxx"
#include "DatabaseRegistry.hxx"
#include "DatabaseSave.hxx"
#include "Directory.hxx"
extern "C" {
#include "database.h"
@@ -30,8 +31,6 @@ extern "C" {
#include "glib_compat.h"
}
#include "directory.h"
#include "DatabasePlugin.hxx"
#include "db/SimpleDatabasePlugin.hxx"

View File

@@ -24,6 +24,7 @@
#include "PlaylistVector.hxx"
#include "SongPrint.hxx"
#include "TimePrint.hxx"
#include "Directory.hxx"
extern "C" {
#include "database.h"
@@ -32,8 +33,6 @@ extern "C" {
#include "tag.h"
}
#include "directory.h"
#include "DatabaseGlue.hxx"
#include "DatabasePlugin.hxx"

View File

@@ -20,7 +20,7 @@
#include "config.h"
#include "DatabaseSave.hxx"
#include "DatabaseLock.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "DirectorySave.hxx"
#include "song.h"

View File

@@ -18,7 +18,7 @@
*/
#include "config.h"
#include "directory.h"
#include "Directory.hxx"
#include "SongFilter.hxx"
#include "PlaylistVector.hxx"
#include "DatabaseLock.hxx"

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2003-2011 The Music Player Daemon Project
* Copyright (C) 2003-2013 The Music Player Daemon Project
* http://www.musicpd.org
*
* This program is free software; you can redistribute it and/or modify
@@ -17,16 +17,13 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
#ifndef MPD_DIRECTORY_H
#define MPD_DIRECTORY_H
#ifndef MPD_DIRECTORY_HXX
#define MPD_DIRECTORY_HXX
#include "check.h"
#include "util/list.h"
#include "gcc.h"
#ifdef __cplusplus
#include "DatabaseVisitor.hxx"
#endif
#include <glib.h>
#include <stdbool.h>
@@ -55,10 +52,7 @@
struct song;
struct db_visitor;
#ifdef __cplusplus
class SongFilter;
#endif
struct directory {
/**
@@ -96,7 +90,6 @@ struct directory {
bool have_stat; /* not needed if ino_t == dev_t == 0 is impossible */
char path[sizeof(long)];
#ifdef __cplusplus
/**
* Caller must lock #db_mutex.
*/
@@ -104,11 +97,8 @@ struct directory {
VisitDirectory visit_directory, VisitSong visit_song,
VisitPlaylist visit_playlist,
GError **error_r) const;
#endif
};
G_BEGIN_DECLS
static inline bool
isRootDirectory(const char *name)
{
@@ -272,6 +262,4 @@ directory_lookup_song(struct directory *directory, const char *uri);
void
directory_sort(struct directory *directory);
G_END_DECLS
#endif

View File

@@ -19,7 +19,7 @@
#include "config.h"
#include "DirectorySave.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "SongSave.hxx"
#include "PlaylistDatabase.hxx"

View File

@@ -23,7 +23,7 @@
#include "config.h"
#include "Mapper.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
extern "C" {

View File

@@ -22,7 +22,7 @@
#include "DatabaseCommands.hxx"
#include "CommandError.hxx"
#include "UpdateGlue.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "SongPrint.hxx"
#include "TagPrint.hxx"

View File

@@ -19,7 +19,7 @@
#include "config.h"
#include "song.h"
#include "directory.h"
#include "Directory.hxx"
extern "C" {
#include "tag.h"

View File

@@ -20,7 +20,7 @@
#include "config.h"
#include "SongPrint.hxx"
#include "song.h"
#include "directory.h"
#include "Directory.hxx"
#include "TimePrint.hxx"
#include "TagPrint.hxx"
#include "Mapper.hxx"

View File

@@ -21,7 +21,7 @@
#include "SongSave.hxx"
#include "song.h"
#include "TagSave.hxx"
#include "directory.h"
#include "Directory.hxx"
extern "C" {
#include "tag.h"

View File

@@ -21,7 +21,7 @@
#include "SongSticker.hxx"
#include "StickerDatabase.hxx"
#include "song.h"
#include "directory.h"
#include "Directory.hxx"
#include <glib.h>

View File

@@ -24,7 +24,7 @@ extern "C" {
#include "uri.h"
}
#include "directory.h"
#include "Directory.hxx"
#include "Mapper.hxx"
extern "C" {

View File

@@ -21,7 +21,7 @@
#include "UpdateArchive.hxx"
#include "UpdateInternal.hxx"
#include "DatabaseLock.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "Mapper.hxx"

View File

@@ -22,7 +22,7 @@
#include "UpdateInternal.hxx"
#include "UpdateDatabase.hxx"
#include "DatabaseLock.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "decoder_plugin.h"
#include "Mapper.hxx"

View File

@@ -21,7 +21,7 @@
#include "UpdateDatabase.hxx"
#include "UpdateRemove.hxx"
#include "PlaylistVector.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "DatabaseLock.hxx"

View File

@@ -19,7 +19,7 @@
#include "config.h" /* must be first for large file support */
#include "UpdateIO.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "Mapper.hxx"
#include "glib_compat.h"

View File

@@ -24,7 +24,7 @@
#include "UpdateDatabase.hxx"
#include "UpdateContainer.hxx"
#include "DatabaseLock.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "decoder_plugin.h"

View File

@@ -24,7 +24,7 @@
#include "UpdateSong.hxx"
#include "UpdateArchive.hxx"
#include "DatabaseLock.hxx"
#include "directory.h"
#include "Directory.hxx"
#include "song.h"
#include "PlaylistVector.hxx"
#include "Mapper.hxx"

View File

@@ -22,6 +22,7 @@
#include "DatabasePlugin.hxx"
#include "DatabaseSelection.hxx"
#include "PlaylistVector.hxx"
#include "Directory.hxx"
#include "gcc.h"
extern "C" {
@@ -31,8 +32,6 @@ extern "C" {
#include "tag.h"
}
#include "directory.h"
#undef MPD_DIRECTORY_H
#undef MPD_SONG_H
#include <mpd/client.h>

View File

@@ -21,6 +21,7 @@
#include "SimpleDatabasePlugin.hxx"
#include "DatabaseSelection.hxx"
#include "DatabaseHelpers.hxx"
#include "Directory.hxx"
#include "SongFilter.hxx"
#include "DatabaseSave.hxx"
#include "DatabaseLock.hxx"
@@ -30,8 +31,6 @@ extern "C" {
#include "conf.h"
}
#include "directory.h"
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>