while converting item in columns to string, if title is empty, use filename
This commit is contained in:
@@ -389,8 +389,15 @@ std::string Playlist::SongInColumnsToString(const MPD::Song &s, void *data)
|
|||||||
std::string fmt = *static_cast<std::string *>(data);
|
std::string fmt = *static_cast<std::string *>(data);
|
||||||
for (std::string i = GetLineValue(fmt, '{', '}', 1); !i.empty(); i = GetLineValue(fmt, '{', '}', 1))
|
for (std::string i = GetLineValue(fmt, '{', '}', 1); !i.empty(); i = GetLineValue(fmt, '{', '}', 1))
|
||||||
{
|
{
|
||||||
result += "%";
|
if (i == "t")
|
||||||
result += i;
|
{
|
||||||
|
result += "{%t}|{%f}";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
result += "%";
|
||||||
|
result += i;
|
||||||
|
}
|
||||||
result += " ";
|
result += " ";
|
||||||
}
|
}
|
||||||
return s.toString(result);
|
return s.toString(result);
|
||||||
|
|||||||
Reference in New Issue
Block a user