mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-09-21 20:06:40 +00:00
Remove CStr::Left
It was only a wrapper around `std::string::substr`. In some places it's better to use `std::string::starts_with`.
This commit is contained in:
@@ -643,7 +643,7 @@ void CConsole::LoadHistory()
|
||||
if (pos != CStrW::npos)
|
||||
{
|
||||
if (pos > 0)
|
||||
m_BufHistory.push_front(str.Left(str[pos-1] == '\r' ? pos - 1 : pos));
|
||||
m_BufHistory.push_front(str.substr(0, str[pos-1] == '\r' ? pos - 1 : pos));
|
||||
str.erase(0, pos + 1);
|
||||
}
|
||||
else if (str.length() > 0)
|
||||
|
||||
Reference in New Issue
Block a user