Skip to content

Commit

Permalink
int math done with floats causes warnings. (#3218)
Browse files Browse the repository at this point in the history
  • Loading branch information
JeffM2501 authored Aug 2, 2023
1 parent b60c691 commit 04678bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rcore.c
Original file line number Diff line number Diff line change
Expand Up @@ -1693,8 +1693,8 @@ void SetWindowMonitor(int monitor)
if ((screenWidth >= monitorWorkareaWidth) || (screenHeight >= monitorWorkareaHeight)) glfwSetWindowPos(CORE.Window.handle, monitorWorkareaX, monitorWorkareaY);
else
{
const int x = monitorWorkareaX + (monitorWorkareaWidth*0.5f) - (screenWidth*0.5f);
const int y = monitorWorkareaY + (monitorWorkareaHeight*0.5f) - (screenHeight*0.5f);
const int x = monitorWorkareaX + (monitorWorkareaWidth/2) - (screenWidth/2);
const int y = monitorWorkareaY + (monitorWorkareaHeight/2) - (screenHeight/2);
glfwSetWindowPos(CORE.Window.handle, x, y);
}
}
Expand Down

0 comments on commit 04678bc

Please sign in to comment.