1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-22 14:24:33 +01:00

Using std::move(), correct clear strings, better use '= default;', modernize make_* and replace heavy strlen

This commit is contained in:
germanaizek
2022-04-25 16:37:32 +03:00
committed by Hielke Morsink
parent 0045aed7f9
commit 958bfbc08a
28 changed files with 59 additions and 67 deletions

View File

@@ -114,7 +114,7 @@ void chat_draw(rct_drawpixelinfo* dpi, uint8_t chatBackgroundColor)
for (int32_t i = 0; i < CHAT_HISTORY_SIZE; i++)
{
if (strlen(chat_history_get(i)) == 0)
if (chat_history_get(i)[0] == '\0')
{
continue;
}
@@ -238,7 +238,7 @@ void chat_input(ChatInput input)
switch (input)
{
case ChatInput::Send:
if (strlen(_chatCurrentLine) > 0)
if (_chatCurrentLine[0] != '\0')
{
network_send_chat(_chatCurrentLine);
}