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:
phosit
2026-08-24 13:34:37 +02:00
parent d8bb617962
commit 60824e77b9
8 changed files with 15 additions and 31 deletions
+1 -1
View File
@@ -109,7 +109,7 @@ SDL_Scancode FindScancode(const CStr8& keyname)
return code;
// Parse SYM_XX codes, see below.
if (keyname.size() > 4 && keyname.Left(4) == "SYM_")
if (keyname.size() > 4 && keyname.starts_with("SYM_"))
return static_cast<SDL_Scancode>(CStr(keyname.substr(4)).ToInt());
return SDL_SCANCODE_UNKNOWN;