cleanup, web interface
This commit is contained in:
@@ -226,15 +226,16 @@ String DirectoryNode::getDirectoryStructureHTML() const
|
||||
{
|
||||
String html;
|
||||
html.reserve(1024); // Reserve memory for better performance
|
||||
|
||||
appendIndentation(html, 0);
|
||||
html += "<ul>\n";
|
||||
appendIndentation(html, 1);
|
||||
html += "<li>" + name + "</li>\n";
|
||||
if (name=="/") {
|
||||
html += "<ul>\n";
|
||||
}
|
||||
|
||||
if (name!="/") {
|
||||
html += "<li><b>" + name + "</b></li>\n";
|
||||
}
|
||||
|
||||
for (const String &mp3File : mp3Files)
|
||||
{
|
||||
appendIndentation(html, 2);
|
||||
html += "<li>" + mp3File + "</li>\n";
|
||||
}
|
||||
|
||||
@@ -242,9 +243,9 @@ String DirectoryNode::getDirectoryStructureHTML() const
|
||||
{
|
||||
html += childNode->getDirectoryStructureHTML();
|
||||
}
|
||||
|
||||
appendIndentation(html, 0);
|
||||
html += "</ul>\n";
|
||||
if (name=="/") {
|
||||
html += "</ul>\n";
|
||||
}
|
||||
|
||||
return html;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user