Rename WINDOW_LIMIT_MIN to kWindowLimitMin

This commit is contained in:
Harry-Hopkinson 2024-04-26 15:28:16 +00:00 committed by Harry Hopkinson
parent 7a1b4ce425
commit 343b10c172
2 changed files with 2 additions and 2 deletions

View File

@ -194,7 +194,7 @@ static void WindowCloseSurplus(int32_t cap, WindowClass avoid_classification)
void WindowSetWindowLimit(int32_t value)
{
int32_t prev = gConfigGeneral.WindowLimit;
int32_t val = std::clamp(value, WINDOW_LIMIT_MIN, WINDOW_LIMIT_MAX);
int32_t val = std::clamp<int32_t>(value, kWindowLimitMin, WINDOW_LIMIT_MAX);
gConfigGeneral.WindowLimit = val;
ConfigSaveDefault();
// Checks if value decreases and then closes surplus

View File

@ -482,7 +482,7 @@ enum class Tool
using modal_callback = void (*)(int32_t result);
using close_callback = void (*)();
#define WINDOW_LIMIT_MIN 4
constexpr int8_t kWindowLimitMin = 4;
#define WINDOW_LIMIT_MAX 64
#define WINDOW_LIMIT_RESERVED 4 // Used to reserve room for the main viewport, toolbars, etc.