Dont replace metadata when loading playlists

This commit is contained in:
Jonas Kvinge
2019-11-20 19:34:57 +01:00
parent 9375d9699a
commit 7795b9edaf
8 changed files with 51 additions and 31 deletions

View File

@@ -121,6 +121,7 @@ bool M3UParser::ParseMetadata(const QString &line, M3UParser::Metadata *metadata
metadata->artist = list[0].trimmed();
metadata->title = list[1].trimmed();
return true;
}
void M3UParser::Save(const SongList &songs, QIODevice *device, const QDir &dir, Playlist::Path path_type) const {
@@ -146,6 +147,7 @@ void M3UParser::Save(const SongList &songs, QIODevice *device, const QDir &dir,
device->write(URLOrFilename(song.url(), dir, path_type).toUtf8());
device->write("\n");
}
}
bool M3UParser::TryMagic(const QByteArray &data) const {