mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-19 12:24:29 +01:00
Add "\n" parsing to i18n code. Move some code from Common.
This commit is contained in:
1 parent
73f5870096
commit
2f46baa138
7 files changed
+155
-3
No files matched your search
@@ -211,3 +211,14 @@ void SplitString(const std::string& str, const char delim, std::vector<std::stri
|
||||
|
||||
output.pop_back();
|
||||
}
|
||||
|
||||
std::string ReplaceAll(std::string result, const std::string& src, const std::string& dest)
|
||||
{
|
||||
while(1)
|
||||
{
|
||||
const size_t pos = result.find(src);
|
||||
if (pos == result.npos) break;
|
||||
result.replace(pos, src.size(), dest);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
Reference in new issue
Block a user