tag: new tag "Mood"
Closes https://github.com/MusicPlayerDaemon/MPD/issues/1435
This commit is contained in:
@@ -201,6 +201,9 @@ static constexpr struct {
|
||||
{ TAG_MOVEMENT, MPD_TAG_MOVEMENT },
|
||||
{ TAG_MOVEMENTNUMBER, MPD_TAG_MOVEMENTNUMBER },
|
||||
{ TAG_LOCATION, MPD_TAG_LOCATION },
|
||||
#endif
|
||||
#if LIBMPDCLIENT_CHECK_VERSION(2,21,0)
|
||||
{ TAG_MOOD, MPD_TAG_MOOD },
|
||||
#endif
|
||||
{ TAG_NUM_OF_ITEM_TYPES, MPD_TAG_COUNT }
|
||||
};
|
||||
|
@@ -60,6 +60,10 @@
|
||||
#define ID3_FRAME_LABEL "TPUB"
|
||||
#endif
|
||||
|
||||
#ifndef ID3_FRAME_MOOD
|
||||
#define ID3_FRAME_MOOD "TMOO"
|
||||
#endif
|
||||
|
||||
gcc_pure
|
||||
static Id3String
|
||||
tag_id3_getstring(const struct id3_frame *frame, unsigned i) noexcept
|
||||
@@ -346,6 +350,7 @@ scan_id3_tag(const struct id3_tag *tag, TagHandler &handler) noexcept
|
||||
handler);
|
||||
tag_id3_import_text(tag, ID3_FRAME_LABEL, TAG_LABEL,
|
||||
handler);
|
||||
tag_id3_import_text(tag, ID3_FRAME_MOOD, TAG_MOOD, handler);
|
||||
|
||||
tag_id3_import_musicbrainz(tag, handler);
|
||||
tag_id3_import_ufid(tag, handler);
|
||||
|
@@ -30,6 +30,7 @@ const char *const tag_item_names[TAG_NUM_OF_ITEM_TYPES] = {
|
||||
[TAG_TRACK] = "Track",
|
||||
[TAG_NAME] = "Name",
|
||||
[TAG_GENRE] = "Genre",
|
||||
[TAG_MOOD] = "Mood",
|
||||
[TAG_DATE] = "Date",
|
||||
[TAG_ORIGINAL_DATE] = "OriginalDate",
|
||||
[TAG_COMPOSER] = "Composer",
|
||||
|
@@ -45,6 +45,7 @@ enum TagType
|
||||
TAG_TRACK,
|
||||
TAG_NAME,
|
||||
TAG_GENRE,
|
||||
TAG_MOOD,
|
||||
TAG_DATE,
|
||||
TAG_ORIGINAL_DATE,
|
||||
TAG_COMPOSER,
|
||||
|
Reference in New Issue
Block a user