aboutsummaryrefslogtreecommitdiff
path: root/backends/base-backend.cpp
diff options
context:
space:
mode:
authorCameron Cawley2019-11-09 14:52:05 +0000
committerFilippos Karapetis2019-11-10 01:25:46 +0200
commitd1fa1154fe5758fe48928062ff9b43d1bcfc7770 (patch)
treeab6e301f5a000c0fdeea52a83c0a92b59b55d68a /backends/base-backend.cpp
parenta00ccb215fcf5657aea797877285c1e7e6cac5f0 (diff)
downloadscummvm-rg350-d1fa1154fe5758fe48928062ff9b43d1bcfc7770.tar.gz
scummvm-rg350-d1fa1154fe5758fe48928062ff9b43d1bcfc7770.tar.bz2
scummvm-rg350-d1fa1154fe5758fe48928062ff9b43d1bcfc7770.zip
BACKENDS: Fix using fillScreen in non-paletted screen modes
Diffstat (limited to 'backends/base-backend.cpp')
-rw-r--r--backends/base-backend.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/backends/base-backend.cpp b/backends/base-backend.cpp
index 3e95c3e26a..9164b8d721 100644
--- a/backends/base-backend.cpp
+++ b/backends/base-backend.cpp
@@ -57,7 +57,7 @@ void BaseBackend::initBackend() {
void BaseBackend::fillScreen(uint32 col) {
Graphics::Surface *screen = lockScreen();
- if (screen && screen->getPixels())
- memset(screen->getPixels(), col, screen->h * screen->pitch);
+ if (screen)
+ screen->fillRect(Common::Rect(screen->w, screen->h), col);
unlockScreen();
}