Update rcore_desktop_glfw.c

Comments updated.
This commit is contained in:
Dave Green 2024-07-27 20:54:09 +02:00 committed by GitHub
parent 1f2b6e13cb
commit 6cec9a59d6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -195,7 +195,7 @@ void ToggleBorderlessWindowed(void)
bool wasOnFullscreen = false; bool wasOnFullscreen = false;
if (CORE.Window.fullscreen) if (CORE.Window.fullscreen)
{ {
//fullscreen already saves previous position so it does not need to be set here again // fullscreen already saves the previous position so it does not need to be set here again
ToggleFullscreen(); ToggleFullscreen();
wasOnFullscreen = true; wasOnFullscreen = true;
} }
@ -593,7 +593,7 @@ void SetWindowTitle(const char *title)
// Set window position on screen (windowed mode) // Set window position on screen (windowed mode)
void SetWindowPosition(int x, int y) void SetWindowPosition(int x, int y)
{ {
//update core window position as well // Update CORE.Window.position as well
CORE.Window.position.x = x; CORE.Window.position.x = x;
CORE.Window.position.y = y; CORE.Window.position.y = y;
glfwSetWindowPos(platform.handle, x, y); glfwSetWindowPos(platform.handle, x, y);
@ -1688,6 +1688,7 @@ static void WindowSizeCallback(GLFWwindow *window, int width, int height)
} }
static void WindowPosCallback(GLFWwindow* window, int x, int y) static void WindowPosCallback(GLFWwindow* window, int x, int y)
{ {
// Set current window position
CORE.Window.position.x = x; CORE.Window.position.x = x;
CORE.Window.position.y = y; CORE.Window.position.y = y;
} }