FIX: support maximum 999 recent projects

Change-Id: I2465990583a1295f40e3c4c6ef9237657e38a91c
Jira: STUDIO-9107
(cherry picked from commit d29fa512acd0c21255fbf8d6f5f0488214677e83)
This commit is contained in:
chunmao.guo
2025-01-08 15:06:46 +08:00
committed by Noisyfox
parent 8fcbe52770
commit 80c4891926
2 changed files with 3 additions and 2 deletions

View File

@@ -1188,7 +1188,8 @@ void AppConfig::set_recent_projects(const std::vector<std::string>& recent_proje
for (unsigned int i = 0; i < (unsigned int)recent_projects.size(); ++i)
{
auto n = std::to_string(i + 1);
if (n.length() == 1) n = "0" + n;
if (n.length() == 1) n = "00" + n;
else if (n.length() == 2) n = "0" + n;
it->second[n] = recent_projects[i];
}
}