X11TK: Use SDL_roundf instead of normal roundf

This commit is contained in:
eafton
2025-09-22 16:10:58 +03:00
committed by Sam Lantinga
parent 667eac3354
commit 8cbd5d5b25

View File

@@ -412,7 +412,7 @@ static void X11Toolkit_SettingsNotify(const char *name, XSettingsAction action,
/* set scale vars */
window->scale = X11Toolkit_GetUIScale(window->xsettings, window->display);
window->iscale = (int)SDL_ceilf(window->scale);
if (roundf(window->scale) == window->scale) {
if (SDL_roundf(window->scale) == window->scale) {
window->scale = 0;
}
@@ -618,7 +618,7 @@ SDL_ToolkitWindowX11 *X11Toolkit_CreateWindowStruct(SDL_Window *parent, SDL_Tool
window->xsettings_first_time = false;
window->scale = X11Toolkit_GetUIScale(window->xsettings, window->display);
window->iscale = (int)SDL_ceilf(window->scale);
if (roundf(window->scale) == window->scale) {
if (SDL_roundf(window->scale) == window->scale) {
window->scale = 0;
}