diff options
author | Max Kellermann <max@musicpd.org> | 2019-08-12 13:27:27 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2019-08-12 20:31:43 +0200 |
commit | 96a1c69c292db2a75aa7c27a3b9872a2252452b1 (patch) | |
tree | 69afbad114f3d759cc12a6f0f9360293f45dd343 /test | |
parent | 3895d35a525bad8c7c02a9dd6ab559e811795d1e (diff) |
tag/Handler: add virtual method OnPicture()
Preparing for https://github.com/MusicPlayerDaemon/MPD/issues/42
Diffstat (limited to 'test')
-rw-r--r-- | test/read_tags.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/test/read_tags.cxx b/test/read_tags.cxx index 5fff8c683..e2f3c01a4 100644 --- a/test/read_tags.cxx +++ b/test/read_tags.cxx @@ -49,7 +49,7 @@ class DumpTagHandler final : public NullTagHandler { public: DumpTagHandler() noexcept - :NullTagHandler(WANT_DURATION|WANT_TAG|WANT_PAIR) {} + :NullTagHandler(WANT_DURATION|WANT_TAG|WANT_PAIR|WANT_PICTURE) {} bool IsEmpty() const noexcept { return empty; @@ -74,6 +74,11 @@ public: void OnAudioFormat(AudioFormat af) noexcept override { printf("%s\n", ToString(af).c_str()); } + + void OnPicture(const char *mime_type, + ConstBuffer<void> buffer) noexcept override { + printf("picture mime='%s' size=%zu\n", mime_type, buffer.size); + } }; int main(int argc, char **argv) |