Fixed SetWindowMouseRect return value on Windows

This commit is contained in:
Sam Lantinga 2021-11-08 16:33:50 -08:00
parent 7d21322df1
commit 2d23d66a61
2 changed files with 4 additions and 2 deletions

View File

@ -814,7 +814,7 @@ void WIN_UngrabKeyboard(SDL_Window *window)
} }
} }
void int
WIN_SetWindowMouseRect(_THIS, SDL_Window * window, SDL_Rect * rect) WIN_SetWindowMouseRect(_THIS, SDL_Window * window, SDL_Rect * rect)
{ {
SDL_WindowData *data = (SDL_WindowData *) window->driverdata; SDL_WindowData *data = (SDL_WindowData *) window->driverdata;
@ -825,6 +825,8 @@ WIN_SetWindowMouseRect(_THIS, SDL_Window * window, SDL_Rect * rect)
SDL_zero(data->mouse_rect); SDL_zero(data->mouse_rect);
} }
WIN_UpdateClipCursor(window); WIN_UpdateClipCursor(window);
return 0;
} }
void void

View File

@ -82,7 +82,7 @@ extern void WIN_SetWindowFullscreen(_THIS, SDL_Window * window, SDL_VideoDisplay
extern int WIN_SetWindowGammaRamp(_THIS, SDL_Window * window, const Uint16 * ramp); extern int WIN_SetWindowGammaRamp(_THIS, SDL_Window * window, const Uint16 * ramp);
extern void* WIN_GetWindowICCProfile(_THIS, SDL_Window * window, size_t * size); extern void* WIN_GetWindowICCProfile(_THIS, SDL_Window * window, size_t * size);
extern int WIN_GetWindowGammaRamp(_THIS, SDL_Window * window, Uint16 * ramp); extern int WIN_GetWindowGammaRamp(_THIS, SDL_Window * window, Uint16 * ramp);
extern void WIN_SetWindowMouseRect(_THIS, SDL_Window * window, SDL_Rect * rect); extern int WIN_SetWindowMouseRect(_THIS, SDL_Window * window, SDL_Rect * rect);
extern void WIN_SetWindowMouseGrab(_THIS, SDL_Window * window, SDL_bool grabbed); extern void WIN_SetWindowMouseGrab(_THIS, SDL_Window * window, SDL_bool grabbed);
extern void WIN_SetWindowKeyboardGrab(_THIS, SDL_Window * window, SDL_bool grabbed); extern void WIN_SetWindowKeyboardGrab(_THIS, SDL_Window * window, SDL_bool grabbed);
extern void WIN_DestroyWindow(_THIS, SDL_Window * window); extern void WIN_DestroyWindow(_THIS, SDL_Window * window);