[Scummvm-cvs-logs] CVS: scummvm/backends/sdl graphics.cpp,1.13,1.14
Torbjörn Andersson
eriktorbjorn at users.sourceforge.net
Tue Oct 12 23:38:07 CEST 2004
Update of /cvsroot/scummvm/scummvm/backends/sdl
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16562
Modified Files:
graphics.cpp
Log Message:
Don't let undraw_mouse() terminate with the surface still locked. Now I can
finally quit Broken Sword II again, without ScummVM crashing.
Index: graphics.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/backends/sdl/graphics.cpp,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- graphics.cpp 28 Sep 2004 20:19:23 -0000 1.13
+++ graphics.cpp 13 Oct 2004 06:36:29 -0000 1.14
@@ -1013,9 +1013,6 @@
return;
_mouseDrawn = false;
- if (SDL_LockSurface(_overlayVisible ? _tmpscreen : _screen) == -1)
- error("SDL_LockSurface failed: %s", SDL_GetError());
-
int old_mouse_x = _mouseCurState.x - _mouseHotspotX;
int old_mouse_y = _mouseCurState.y - _mouseHotspotY;
int old_mouse_w = _mouseCurState.w;
@@ -1040,6 +1037,8 @@
if (old_mouse_w <= 0 || old_mouse_h <= 0)
return;
+ if (SDL_LockSurface(_overlayVisible ? _tmpscreen : _screen) == -1)
+ error("SDL_LockSurface failed: %s", SDL_GetError());
int x, y;
if (!_overlayVisible) {
More information about the Scummvm-git-logs
mailing list