Song select: show the song count on folders without an explanation #72

Merged
GanYiZhong merged 1 commits from GanYiZhong/YataiDONNijiiro:fix/folder-count-fallback into main 2026-10-15 17:41:23 +02:00
@@ -127,6 +127,9 @@ function SongSelect:draw_folder_board(box, pb, ch_alpha, ch_off, ta, glow_a)
for _, l in ipairs(box:explanation() or {}) do for _, l in ipairs(box:explanation() or {}) do
if l ~= "" then lines[#lines + 1] = l end if l ~= "" then lines[#lines + 1] = l end
end end
-- folders without an explanation show their song count, as before
local n = box.tja_count
if #lines == 0 and n and n > 0 then lines[1] = tostring(n) .. " songs" end
for i, l in ipairs(lines) do for i, l in ipairs(lines) do
local ckey = frame .. "\0" .. l local ckey = frame .. "\0" .. l
local label = self._count_cache[ckey] local label = self._count_cache[ckey]