aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Horn2003-01-09 16:57:09 +0000
committerMax Horn2003-01-09 16:57:09 +0000
commit1934269872eea22700803ba3e9d53f922a35eb31 (patch)
tree1d3bb7827a19a22c8d5927c45d0b23c00b0f14af
parent80fde145481e56f82d589b51f9105152ee2f7dcf (diff)
downloadscummvm-rg350-1934269872eea22700803ba3e9d53f922a35eb31.tar.gz
scummvm-rg350-1934269872eea22700803ba3e9d53f922a35eb31.tar.bz2
scummvm-rg350-1934269872eea22700803ba3e9d53f922a35eb31.zip
yet another warp mouse change, now it works on OS X, but will it work on Linux/Windows?
svn-id: r6370
-rw-r--r--backends/sdl/sdl-common.cpp2
-rw-r--r--scumm/script_v8.cpp10
2 files changed, 11 insertions, 1 deletions
diff --git a/backends/sdl/sdl-common.cpp b/backends/sdl/sdl-common.cpp
index 32a885fecf..5f0b58e561 100644
--- a/backends/sdl/sdl-common.cpp
+++ b/backends/sdl/sdl-common.cpp
@@ -406,7 +406,7 @@ void OSystem_SDL_Common::warp_mouse(int x, int y) {
if (_full_screen) SDL_ShowCursor(SDL_ENABLE);
SDL_WarpMouse(x * _scaleFactor, y * _scaleFactor);
if (_full_screen) SDL_ShowCursor(SDL_DISABLE);
- set_mouse_pos(x, y);
+// set_mouse_pos(x, y);
}
void OSystem_SDL_Common::set_mouse_cursor(const byte *buf, uint w, uint h, int hotspot_x, int hotspot_y) {
diff --git a/scumm/script_v8.cpp b/scumm/script_v8.cpp
index 186e95d7ee..7dec6f626c 100644
--- a/scumm/script_v8.cpp
+++ b/scumm/script_v8.cpp
@@ -801,6 +801,15 @@ void Scumm_v8::o8_cursorCommand()
_charsetColorMap[i] = _charsetData[_string[1].t_charset][i] = (unsigned char)args[i];
break;
case 0xE9: // SO_CURSOR_PUT
+#if 1
+ {
+ int y = pop();
+ int x = pop();
+
+ _system->warp_mouse(x, y);
+ _system->update_screen();
+ }
+#else
_virtual_mouse_y = pop();
_virtual_mouse_x = pop();
@@ -811,6 +820,7 @@ void Scumm_v8::o8_cursorCommand()
_system->warp_mouse(mouse.x, mouse.y);
_system->update_screen();
// warning("warped mouse to (%d, %d) from %d-%d", _virtual_mouse_x, _virtual_mouse_y, _roomResource, vm.slot[_currentScript].number);
+#endif
break;
default:
error("o8_cursorCommand: default case 0x%x", subOp);