From f3b4f9d640cbd8795b481d71bb9aafa0070db464 Mon Sep 17 00:00:00 2001 From: Peter Nelson Date: Sat, 9 Sep 2023 16:40:59 +0100 Subject: [PATCH] Codechange: Reduce size of TextEffectMode and TextEffectID. TextEffectID was promoted to size_t in #9235, when it was used in loops. However since then the relevant code uses range-for or iterators instead. --- src/texteff.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/texteff.hpp b/src/texteff.hpp index 5f5010c55c..dad9b5888d 100644 --- a/src/texteff.hpp +++ b/src/texteff.hpp @@ -17,12 +17,12 @@ /** * Text effect modes. */ -enum TextEffectMode { +enum TextEffectMode : uint8_t { TE_RISING, ///< Make the text effect slowly go upwards TE_STATIC, ///< Keep the text effect static }; -typedef size_t TextEffectID; +using TextEffectID = uint16_t; static const TextEffectID INVALID_TE_ID = UINT16_MAX;