Merge pull request #1267 from forkiesassds/master

Change SDL_TRUE to true for SDL3 backend
This commit is contained in:
UnknownShadow200 2024-10-11 07:56:24 +11:00 committed by GitHub
commit d3f4bcdf53
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -223,13 +223,13 @@ static int MapNativeKey(SDL_Keycode k) {
}
static void OnKeyEvent(const SDL_Event* e) {
cc_bool pressed = e->key.down == SDL_TRUE;
cc_bool pressed = e->key.down == true;
int key = MapNativeKey(e->key.key);
if (key) Input_Set(key, pressed);
}
static void OnMouseEvent(const SDL_Event* e) {
cc_bool pressed = e->button.down == SDL_TRUE;
cc_bool pressed = e->button.down == true;
int btn;
switch (e->button.button) {
case SDL_BUTTON_LEFT: btn = CCMOUSE_L; break;
@ -613,4 +613,4 @@ void GLContext_SetVSync(cc_bool vsync) {
}
void GLContext_GetApiInfo(cc_string* info) { }
#endif
#endif
#endif