[Scummvm-git-logs] scummvm master -> 6bad1ba0ff7e8c14f567e0014a9a54d4a68c83ed

lephilousophe noreply at scummvm.org
Sat Jan 8 10:14:04 UTC 2022


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
6bad1ba0ff SDL: SDL_SetWindowMouseRect is in 2.0.18 according to the documentation


Commit: 6bad1ba0ff7e8c14f567e0014a9a54d4a68c83ed
    https://github.com/scummvm/scummvm/commit/6bad1ba0ff7e8c14f567e0014a9a54d4a68c83ed
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2022-01-08T11:13:15+01:00

Commit Message:
SDL: SDL_SetWindowMouseRect is in 2.0.18 according to the documentation

2.0.17 is a development version while 2.0.18 is the first release
containing this function.

Changed paths:
    backends/platform/sdl/sdl-window.cpp


diff --git a/backends/platform/sdl/sdl-window.cpp b/backends/platform/sdl/sdl-window.cpp
index 2d8af117239..d156a16a141 100644
--- a/backends/platform/sdl/sdl-window.cpp
+++ b/backends/platform/sdl/sdl-window.cpp
@@ -150,7 +150,7 @@ void SdlWindow::grabMouse(bool grab) {
 #if SDL_VERSION_ATLEAST(2, 0, 0)
 	if (_window) {
 		SDL_SetWindowGrab(_window, grab ? SDL_TRUE : SDL_FALSE);
-#if SDL_VERSION_ATLEAST(2, 0, 17)
+#if SDL_VERSION_ATLEAST(2, 0, 18)
 		SDL_SetWindowMouseRect(_window, grab ? &grabRect : NULL);
 #endif
 	}
@@ -173,7 +173,7 @@ void SdlWindow::setMouseRect(const Common::Rect &rect) {
 	grabRect.w = rect.width();
 	grabRect.h = rect.height();
 
-#if SDL_VERSION_ATLEAST(2, 0, 17)
+#if SDL_VERSION_ATLEAST(2, 0, 18)
 	if (_inputGrabState || _lastFlags & fullscreenMask) {
 		SDL_SetWindowMouseRect(_window, &grabRect);
 	}
@@ -413,7 +413,7 @@ bool SdlWindow::createOrUpdateWindow(int width, int height, uint32 flags) {
 
 	const bool shouldGrab = (flags & SDL_WINDOW_INPUT_GRABBED) || fullscreenFlags;
 	SDL_SetWindowGrab(_window, shouldGrab ? SDL_TRUE : SDL_FALSE);
-#if SDL_VERSION_ATLEAST(2, 0, 17)
+#if SDL_VERSION_ATLEAST(2, 0, 18)
 	SDL_SetWindowMouseRect(_window, shouldGrab ? &grabRect : NULL);
 #endif
 




More information about the Scummvm-git-logs mailing list