fix broken compilation due to lack of setters for mpd_song
This commit is contained in:
13
src/song.h
13
src/song.h
@@ -21,6 +21,7 @@
|
||||
#ifndef _SONG_H
|
||||
#define _SONG_H
|
||||
|
||||
#include <map>
|
||||
#include <string>
|
||||
|
||||
#include <mpd/client.h>
|
||||
@@ -29,13 +30,14 @@ namespace MPD
|
||||
{
|
||||
class Song
|
||||
{
|
||||
typedef std::map<std::pair<mpd_tag_type, unsigned>, std::string> TagMap;
|
||||
|
||||
public:
|
||||
|
||||
typedef void (Song::*SetFunction)(const std::string &);
|
||||
typedef std::string (Song::*GetFunction)() const;
|
||||
|
||||
Song() : itsSong(0), itsFile(0), itsSlash(std::string::npos), itsHash(0), copyPtr(0), isLocalised(0) { }
|
||||
Song(mpd_song *, bool = 0);
|
||||
Song(mpd_song * = 0, bool = 0);
|
||||
Song(const Song &);
|
||||
~Song();
|
||||
|
||||
@@ -73,7 +75,6 @@ namespace MPD
|
||||
void SetDisc(const std::string &);
|
||||
void SetComment(const std::string &);
|
||||
void SetPosition(unsigned);
|
||||
void SetLength(unsigned);
|
||||
|
||||
void SetNewName(const std::string &name) { itsNewName = name == GetName() ? "" : name; }
|
||||
std::string GetNewName() const { return itsNewName; }
|
||||
@@ -99,6 +100,9 @@ namespace MPD
|
||||
void SetHashAndSlash();
|
||||
std::string ParseFormat(std::string::const_iterator &it) const;
|
||||
|
||||
void SetTag(mpd_tag_type, unsigned, const std::string &);
|
||||
std::string GetTag(mpd_tag_type, unsigned) const;
|
||||
|
||||
/// Used internally for handling filename, since we don't have
|
||||
/// write access to file string in mpd_song, manage our own if
|
||||
/// localization was done and there is localized filename that
|
||||
@@ -112,6 +116,9 @@ namespace MPD
|
||||
/// localized version of filename
|
||||
const char *itsFile;
|
||||
|
||||
/// map that contains localized tags or these set by tag editor
|
||||
TagMap *itsTags;
|
||||
|
||||
std::string itsNewName;
|
||||
|
||||
size_t itsSlash;
|
||||
|
||||
Reference in New Issue
Block a user