Changed enums to use XXX_COUNT for the count or number of values

Fixes https://github.com/libsdl-org/SDL/issues/10763
This commit is contained in:
Sam Lantinga
2024-09-11 08:08:18 -07:00
parent 64f12bea4a
commit 37c9fb490e
49 changed files with 197 additions and 174 deletions

View File

@@ -219,8 +219,8 @@ static SDL_Cursor *init_system_cursor(const char *image[])
static SDLTest_CommonState *state;
static int done;
static SDL_Cursor *cursors[3 + SDL_NUM_SYSTEM_CURSORS];
static SDL_SystemCursor cursor_types[3 + SDL_NUM_SYSTEM_CURSORS];
static SDL_Cursor *cursors[3 + SDL_SYSTEM_CURSOR_COUNT];
static SDL_SystemCursor cursor_types[3 + SDL_SYSTEM_CURSOR_COUNT];
static int num_cursors;
static int current_cursor;
static SDL_bool show_cursor;
@@ -437,7 +437,7 @@ int main(int argc, char *argv[])
num_cursors++;
}
for (i = 0; i < SDL_NUM_SYSTEM_CURSORS; ++i) {
for (i = 0; i < SDL_SYSTEM_CURSOR_COUNT; ++i) {
cursor = SDL_CreateSystemCursor((SDL_SystemCursor)i);
if (cursor) {
cursors[num_cursors] = cursor;