summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorRay <[email protected]>2023-10-14 10:56:09 +0200
committerRay <[email protected]>2023-10-14 10:56:09 +0200
commit005ba155c0b4d8e065e6e3ffe2cdd82bb41bf200 (patch)
tree0aeb8dc2e3e8a752123619cc025294db60bb4722
parent2f08f435b91a08c57bf7e381a46381770a00791e (diff)
downloadraylib-005ba155c0b4d8e065e6e3ffe2cdd82bb41bf200.tar.gz
raylib-005ba155c0b4d8e065e6e3ffe2cdd82bb41bf200.zip
Minor tweaks
-rw-r--r--src/rcore.c4
-rw-r--r--src/rcore_desktop.c2
-rw-r--r--src/rcore_web.c2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/rcore.c b/src/rcore.c
index 3efa67b2..b3e07f95 100644
--- a/src/rcore.c
+++ b/src/rcore.c
@@ -2812,7 +2812,7 @@ static void RecordAutomationEvent(unsigned int frame)
// INPUT_GAMEPAD_CONNECT
/*
if ((CORE.Input.Gamepad.currentState[gamepad] != CORE.Input.Gamepad.previousState[gamepad]) &&
- (CORE.Input.Gamepad.currentState[gamepad] == true)) // Check if changed to ready
+ (CORE.Input.Gamepad.currentState[gamepad])) // Check if changed to ready
{
// TODO: Save gamepad connect event
}
@@ -2821,7 +2821,7 @@ static void RecordAutomationEvent(unsigned int frame)
// INPUT_GAMEPAD_DISCONNECT
/*
if ((CORE.Input.Gamepad.currentState[gamepad] != CORE.Input.Gamepad.previousState[gamepad]) &&
- (CORE.Input.Gamepad.currentState[gamepad] == false)) // Check if changed to not-ready
+ (!CORE.Input.Gamepad.currentState[gamepad])) // Check if changed to not-ready
{
// TODO: Save gamepad disconnect event
}
diff --git a/src/rcore_desktop.c b/src/rcore_desktop.c
index c2e5b23f..8fa1edd7 100644
--- a/src/rcore_desktop.c
+++ b/src/rcore_desktop.c
@@ -1966,7 +1966,7 @@ static void MouseScrollCallback(GLFWwindow *window, double xoffset, double yoffs
// GLFW3 CursorEnter Callback, when cursor enters the window
static void CursorEnterCallback(GLFWwindow *window, int enter)
{
- if (enter == true) CORE.Input.Mouse.cursorOnScreen = true;
+ if (enter) CORE.Input.Mouse.cursorOnScreen = true;
else CORE.Input.Mouse.cursorOnScreen = false;
}
diff --git a/src/rcore_web.c b/src/rcore_web.c
index 261498a5..c0b7079b 100644
--- a/src/rcore_web.c
+++ b/src/rcore_web.c
@@ -1336,7 +1336,7 @@ static void MouseScrollCallback(GLFWwindow *window, double xoffset, double yoffs
// GLFW3 CursorEnter Callback, when cursor enters the window
static void CursorEnterCallback(GLFWwindow *window, int enter)
{
- if (enter == true) CORE.Input.Mouse.cursorOnScreen = true;
+ if (enter) CORE.Input.Mouse.cursorOnScreen = true;
else CORE.Input.Mouse.cursorOnScreen = false;
}