Skip to content

Commit

Permalink
fix the issue with GetScreenWidth/GetScreenHeight that was identified…
Browse files Browse the repository at this point in the history
… on other platforms (#4451)
  • Loading branch information
archewashi authored Oct 30, 2024
1 parent ad79d4a commit 3bad05a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/platforms/rcore_desktop_rgfw.c
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,9 @@ void SetWindowMaxSize(int width, int height)
// Set window dimensions
void SetWindowSize(int width, int height)
{
CORE.Window.screen.width = width;
CORE.Window.screen.height = height;

RGFW_window_resize(platform.window, RGFW_AREA(width, height));
}

Expand Down
3 changes: 3 additions & 0 deletions src/platforms/rcore_web.c
Original file line number Diff line number Diff line change
Expand Up @@ -667,6 +667,9 @@ void SetWindowMaxSize(int width, int height)
// Set window dimensions
void SetWindowSize(int width, int height)
{
CORE.Window.screen.width = width;
CORE.Window.Screen.height = height;

glfwSetWindowSize(platform.handle, width, height);
}

Expand Down

0 comments on commit 3bad05a

Please sign in to comment.