summaryrefslogtreecommitdiff
path: root/src/song/LightSong.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'src/song/LightSong.hxx')
-rw-r--r--src/song/LightSong.hxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/song/LightSong.hxx b/src/song/LightSong.hxx
index ee372576a..06f0a41f9 100644
--- a/src/song/LightSong.hxx
+++ b/src/song/LightSong.hxx
@@ -88,6 +88,19 @@ struct LightSong {
LightSong(const char *_uri, const Tag &_tag) noexcept
:uri(_uri), tag(_tag) {}
+ /**
+ * A copy constructor which copies all fields, but only sets
+ * the tag to a caller-provided reference. This is used by
+ * the #ExportedSong move constructor.
+ */
+ LightSong(const LightSong &src, const Tag &_tag) noexcept
+ :directory(src.directory), uri(src.uri),
+ real_uri(src.real_uri),
+ tag(_tag),
+ mtime(src.mtime),
+ start_time(src.start_time), end_time(src.end_time),
+ audio_format(src.audio_format) {}
+
gcc_pure
std::string GetURI() const noexcept {
if (directory == nullptr)