diff options
author | Torbjörn Andersson | 2006-05-24 21:04:44 +0000 |
---|---|---|
committer | Torbjörn Andersson | 2006-05-24 21:04:44 +0000 |
commit | 935d3bb4254365e557642b2713eca8b31ab3eb86 (patch) | |
tree | ad6a2963fe6273d178584f0241b71761b4b5426c /backends/sdl | |
parent | 30b368643e24c1733a99bb52a68a3acb086fc069 (diff) | |
download | scummvm-rg350-935d3bb4254365e557642b2713eca8b31ab3eb86.tar.gz scummvm-rg350-935d3bb4254365e557642b2713eca8b31ab3eb86.tar.bz2 scummvm-rg350-935d3bb4254365e557642b2713eca8b31ab3eb86.zip |
The AGI engine's save/load dialog dirties the entire screen thirteen times
each iteration of the loop, causing a serious slowdown on my computer. It
empathically should not be doing that, of course, but to safe-guard against
such patological cases, if the entire screen is dirtied even once we can set
_forceFull to true.
svn-id: r22616
Diffstat (limited to 'backends/sdl')
-rw-r--r-- | backends/sdl/graphics.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/backends/sdl/graphics.cpp b/backends/sdl/graphics.cpp index b733921b65..8baeb94ab8 100644 --- a/backends/sdl/graphics.cpp +++ b/backends/sdl/graphics.cpp @@ -907,6 +907,11 @@ void OSystem_SDL::addDirtyRect(int x, int y, int w, int h) { } #endif + if (w == width && h == height) { + _forceFull = true; + return; + } + if (w > 0 && h > 0) { SDL_Rect *r = &_dirtyRectList[_numDirtyRects++]; |