aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/graphics/maciconbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sci/graphics/maciconbar.cpp')
-rw-r--r--engines/sci/graphics/maciconbar.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/engines/sci/graphics/maciconbar.cpp b/engines/sci/graphics/maciconbar.cpp
index 2ce17ab531..77491aa995 100644
--- a/engines/sci/graphics/maciconbar.cpp
+++ b/engines/sci/graphics/maciconbar.cpp
@@ -29,6 +29,7 @@
#include "sci/engine/state.h"
#include "sci/graphics/maciconbar.h"
#include "sci/graphics/palette.h"
+#include "sci/graphics/screen.h"
#include "common/memstream.h"
#include "common/system.h"
@@ -58,7 +59,8 @@ void GfxMacIconBar::drawIcons() {
Graphics::Surface *surf = pict->decodeImage(stream, pal);
remapColors(surf, pal);
- g_system->copyRectToScreen((byte *)surf->pixels, surf->pitch, lastX, 200, MIN<uint32>(surf->w, 320 - lastX), surf->h);
+ g_system->copyRectToScreen((byte *)surf->pixels, surf->pitch, lastX,
+ g_sci->_gfxScreen->getHeight() + 2, MIN<uint32>(surf->w, 320 - lastX), surf->h);
lastX += surf->w;
surf->free();
@@ -81,11 +83,7 @@ void GfxMacIconBar::remapColors(Graphics::Surface *surf, byte *palette) {
byte g = palette[color * 4 + 1];
byte b = palette[color * 4 + 2];
- // For black, make sure the index is 0
- if (r == 0 && g == 0 && b == 0)
- *pixels++ = 0;
- else
- *pixels++ = g_sci->_gfxPalette->kernelFindColor(r, g, b);
+ *pixels++ = g_sci->_gfxPalette->findMacIconBarColor(r, g, b);
}
}