diff options
author | Max Horn | 2007-02-08 22:54:09 +0000 |
---|---|---|
committer | Max Horn | 2007-02-08 22:54:09 +0000 |
commit | 2232047695d8d26542c2f57d1c1daed7bfe4f5c5 (patch) | |
tree | 279d0ec8fedee35ec75cedfbb9fc8767de52ba89 /backends/platform | |
parent | af8cba43acedb53a7caa711f743f8d5e0bcc07e6 (diff) | |
download | scummvm-rg350-2232047695d8d26542c2f57d1c1daed7bfe4f5c5.tar.gz scummvm-rg350-2232047695d8d26542c2f57d1c1daed7bfe4f5c5.tar.bz2 scummvm-rg350-2232047695d8d26542c2f57d1c1daed7bfe4f5c5.zip |
The restriction on 'small' mouse cursors has been lifted quite some time ago; PalmOS and WinCE port should be extended accordingly (in particular, the PalmOS port would silently overwrite its memory when big cursors are used)
svn-id: r25431
Diffstat (limited to 'backends/platform')
-rw-r--r-- | backends/platform/PalmOS/Src/os5_mouse.cpp | 9 | ||||
-rw-r--r-- | backends/platform/sdl/sdl-common.h | 3 | ||||
-rw-r--r-- | backends/platform/wince/wince-sdl.cpp | 7 |
3 files changed, 15 insertions, 4 deletions
diff --git a/backends/platform/PalmOS/Src/os5_mouse.cpp b/backends/platform/PalmOS/Src/os5_mouse.cpp index 375dc125ce..20e725694c 100644 --- a/backends/platform/PalmOS/Src/os5_mouse.cpp +++ b/backends/platform/PalmOS/Src/os5_mouse.cpp @@ -41,6 +41,15 @@ void OSystem_PalmOS5::setMouseCursor(const byte *buf, uint w, uint h, int hotspo if (w == 0 || h == 0) return; +FIXME: The restriction on MAX_MOUSE_H / MAX_MOUSE_W is obsolete; +in particular, BS2 might use bigger cursors these days. +See also bug #1609058. 1607180 +Hence this code now might overwrite memory unchecked; at the +very least an assert should be inserted to cause a controlled +crash, but of course it would be better to remove the restriction +on "small" cursors. + + _mouseCurState.w = w; _mouseCurState.h = h; diff --git a/backends/platform/sdl/sdl-common.h b/backends/platform/sdl/sdl-common.h index 27a4d25e78..2a5b88cef2 100644 --- a/backends/platform/sdl/sdl-common.h +++ b/backends/platform/sdl/sdl-common.h @@ -283,9 +283,6 @@ protected: enum { NUM_DIRTY_RECT = 100, - - MAX_MOUSE_W = 80, - MAX_MOUSE_H = 80, MAX_SCALING = 3 }; diff --git a/backends/platform/wince/wince-sdl.cpp b/backends/platform/wince/wince-sdl.cpp index 4a3b657155..c316274657 100644 --- a/backends/platform/wince/wince-sdl.cpp +++ b/backends/platform/wince/wince-sdl.cpp @@ -851,7 +851,7 @@ void OSystem_WINCE3::update_game_settings() { if (ConfMan.hasKey("landscape")) if (ConfMan.get("landscape")[0] > 57) { _newOrientation = _orientationLandscape = ConfMan.getBool("landscape"); - //ConfMan.removeKey("landscape", String::emptyString); + //ConfMan.removeKey("landscape", ""); ConfMan.setInt("landscape", _orientationLandscape); } else _newOrientation = _orientationLandscape = ConfMan.getInt("landscape"); @@ -1704,6 +1704,11 @@ void OSystem_WINCE3::setMouseCursor(const byte *buf, uint w, uint h, int hotspot if (w == 0 || h == 0) return; +/* +FIXME: The restriction on MAX_MOUSE_H / MAX_MOUSE_W is obsolete; +in particular, BS2 might use bigger cursors these days. +See also bug #1609058. 1607180 +*/ assert(w <= MAX_MOUSE_W); assert(h <= MAX_MOUSE_H); _mouseCurState.w = w; |