Fill box routines do not translate the fill box coordinates

svn-id: r44937
This commit is contained in:
Filippos Karapetis 2009-10-11 18:41:13 +00:00
parent 16e852159a
commit 222b0d3887
2 changed files with 3 additions and 10 deletions

View file

@ -396,23 +396,17 @@ void SciGui::editControl(reg_t controlObject, reg_t eventObject) {
void SciGui::graphFillBoxForeground(Common::Rect rect) {
_gfx->PaintRect(rect);
Common::Rect screenRect = rect;
_gfx->OffsetRect(screenRect);
_screen->copyRectToScreen(screenRect);
_screen->copyRectToScreen(rect);
}
void SciGui::graphFillBoxBackground(Common::Rect rect) {
_gfx->EraseRect(rect);
Common::Rect screenRect = rect;
_gfx->OffsetRect(screenRect);
_screen->copyRectToScreen(screenRect);
_screen->copyRectToScreen(rect);
}
void SciGui::graphFillBox(Common::Rect rect, uint16 colorMask, int16 color, int16 priority, int16 control) {
_gfx->FillRect(rect, colorMask, color, priority, control);
Common::Rect screenRect = rect;
_gfx->OffsetRect(screenRect);
_screen->copyRectToScreen(screenRect);
_screen->copyRectToScreen(rect);
}
void SciGui::graphDrawLine(Common::Point startPoint, Common::Point endPoint, int16 color, int16 priority, int16 control) {

View file

@ -75,7 +75,6 @@ void SciGuiScreen::copyToScreen() {
}
void SciGuiScreen::copyRectToScreen(const Common::Rect &rect) {
//g_system->copyRectToScreen(_activeScreen, _displayWidth, 0, 0, _displayWidth, _displayHeight);
g_system->copyRectToScreen(_activeScreen + rect.top * _displayWidth + rect.left, _displayWidth, rect.left, rect.top, rect.width(), rect.height());
}