diff options
author | Max Kellermann <max@duempel.org> | 2013-01-02 23:06:20 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-01-03 01:10:47 +0100 |
commit | 3e8047e5831b4cc7dabae596746066698ad7c8cd (patch) | |
tree | 51cf8e3cc3b5b373f11ffbd6d7c0b34b3c0acb6c /src/db | |
parent | 440ac51cf0250904813dfc9398ca8c9e6467328f (diff) | |
download | mpd-3e8047e5831b4cc7dabae596746066698ad7c8cd.tar.gz mpd-3e8047e5831b4cc7dabae596746066698ad7c8cd.tar.xz mpd-3e8047e5831b4cc7dabae596746066698ad7c8cd.zip |
Directory: rename struct directory to Directory
Diffstat (limited to 'src/db')
-rw-r--r-- | src/db/ProxyDatabasePlugin.cxx | 7 | ||||
-rw-r--r-- | src/db/SimpleDatabasePlugin.cxx | 8 | ||||
-rw-r--r-- | src/db/SimpleDatabasePlugin.hxx | 8 |
3 files changed, 11 insertions, 12 deletions
diff --git a/src/db/ProxyDatabasePlugin.cxx b/src/db/ProxyDatabasePlugin.cxx index 938440046..e41ee8819 100644 --- a/src/db/ProxyDatabasePlugin.cxx +++ b/src/db/ProxyDatabasePlugin.cxx @@ -45,7 +45,7 @@ class ProxyDatabase : public Database { unsigned port; struct mpd_connection *connection; - struct directory *root; + Directory *root; public: static Database *Create(const struct config_param *param, @@ -168,7 +168,7 @@ ProxyDatabase::Open(GError **error_r) return false; } - root = directory::NewRoot(); + root = Directory::NewRoot(); return true; } @@ -240,8 +240,7 @@ Visit(struct mpd_connection *connection, const char *path = mpd_directory_get_path(directory); if (visit_directory) { - struct directory *d = - directory::NewGeneric(path, &detached_root); + Directory *d = Directory::NewGeneric(path, &detached_root); bool success = visit_directory(*d, error_r); d->Free(); if (!success) diff --git a/src/db/SimpleDatabasePlugin.cxx b/src/db/SimpleDatabasePlugin.cxx index ac2de1b61..04e319498 100644 --- a/src/db/SimpleDatabasePlugin.cxx +++ b/src/db/SimpleDatabasePlugin.cxx @@ -180,7 +180,7 @@ SimpleDatabase::Load(GError **error_r) bool SimpleDatabase::Open(GError **error_r) { - root = directory::NewRoot(); + root = Directory::NewRoot(); mtime = 0; #ifndef NDEBUG @@ -197,7 +197,7 @@ SimpleDatabase::Open(GError **error_r) if (!Check(error_r)) return false; - root = directory::NewRoot(); + root = Directory::NewRoot(); } return true; @@ -243,7 +243,7 @@ SimpleDatabase::ReturnSong(gcc_unused struct song *song) const } G_GNUC_PURE -const struct directory * +const Directory * SimpleDatabase::LookupDirectory(const char *uri) const { assert(root != NULL); @@ -262,7 +262,7 @@ SimpleDatabase::Visit(const DatabaseSelection &selection, { ScopeDatabaseLock protect; - const directory *directory = root->LookupDirectory(selection.uri); + const Directory *directory = root->LookupDirectory(selection.uri); if (directory == NULL) { if (visit_song) { song *song = root->LookupSong(selection.uri); diff --git a/src/db/SimpleDatabasePlugin.hxx b/src/db/SimpleDatabasePlugin.hxx index 4de39b46c..789dcdae9 100644 --- a/src/db/SimpleDatabasePlugin.hxx +++ b/src/db/SimpleDatabasePlugin.hxx @@ -28,12 +28,12 @@ #include <time.h> -struct directory; +struct Directory; class SimpleDatabase : public Database { std::string path; - struct directory *root; + Directory *root; time_t mtime; @@ -43,7 +43,7 @@ class SimpleDatabase : public Database { public: gcc_pure - struct directory *GetRoot() { + Directory *GetRoot() { assert(root != NULL); return root; @@ -90,7 +90,7 @@ protected: bool Load(GError **error_r); gcc_pure - const struct directory *LookupDirectory(const char *uri) const; + const Directory *LookupDirectory(const char *uri) const; }; extern const DatabasePlugin simple_db_plugin; |