Skip to content

Commit 7006314

Browse files
committed
sdl3(display): fix warnings with SDL_WindowFlags
1 parent c685250 commit 7006314

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src_c/display.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ pg_get_init(PyObject *self, PyObject *_null)
279279
static PyObject *
280280
pg_get_active(PyObject *self, PyObject *_null)
281281
{
282-
Uint32 flags = SDL_GetWindowFlags(pg_GetDefaultWindow());
282+
SDL_WindowFlags flags = SDL_GetWindowFlags(pg_GetDefaultWindow());
283283

284284
#if SDL_VERSION_ATLEAST(3, 0, 0)
285285
return PyBool_FromLong(!(flags & SDL_WINDOW_HIDDEN) &&
@@ -2799,7 +2799,7 @@ static PyObject *
27992799
pg_is_fullscreen(PyObject *self, PyObject *_null)
28002800
{
28012801
SDL_Window *win = pg_GetDefaultWindow();
2802-
int flags;
2802+
SDL_WindowFlags flags;
28032803

28042804
VIDEO_INIT_CHECK();
28052805
if (!win) {
@@ -3033,7 +3033,8 @@ static PyObject *
30333033
pg_toggle_fullscreen(PyObject *self, PyObject *_null)
30343034
{
30353035
SDL_Window *win = pg_GetDefaultWindow();
3036-
int result, flags;
3036+
int result;
3037+
SDL_WindowFlags flags;
30373038
int window_w, window_h, w, h, window_display, x, y;
30383039
pgSurfaceObject *display_surface;
30393040
_DisplayState *state = DISPLAY_MOD_STATE(self);
@@ -3473,7 +3474,7 @@ pg_display_resize_event(PyObject *self, PyObject *event)
34733474
int wnew = PyLong_AsLong(PyObject_GetAttrString(event, "w"));
34743475
int hnew = PyLong_AsLong(PyObject_GetAttrString(event, "h"));
34753476
SDL_Window *win = pg_GetDefaultWindow();
3476-
int flags;
3477+
SDL_WindowFlags flags;
34773478
int w, h, result;
34783479
_DisplayState *state = DISPLAY_MOD_STATE(self);
34793480
GL_glViewport_Func p_glViewport = NULL;

0 commit comments

Comments
 (0)