diff options
author | Einar Johan Trøan Sømåen | 2013-10-29 02:55:31 +0100 |
---|---|---|
committer | Einar Johan Trøan Sømåen | 2013-10-29 02:59:53 +0100 |
commit | d6b9d7de8f4bc8be34ef7456a89ee144172ca5b0 (patch) | |
tree | 9c5d5025bdff5681f7fe2030b496677d54625bc8 /engines/wintermute/base/base_sub_frame.cpp | |
parent | efb8031b3c38b8d7e2da73725eb60a35554d0508 (diff) | |
download | scummvm-rg350-d6b9d7de8f4bc8be34ef7456a89ee144172ca5b0.tar.gz scummvm-rg350-d6b9d7de8f4bc8be34ef7456a89ee144172ca5b0.tar.bz2 scummvm-rg350-d6b9d7de8f4bc8be34ef7456a89ee144172ca5b0.zip |
WINTERMUTE: Remove BasePlatform::setRect (replace with member-call)
Diffstat (limited to 'engines/wintermute/base/base_sub_frame.cpp')
-rw-r--r-- | engines/wintermute/base/base_sub_frame.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/engines/wintermute/base/base_sub_frame.cpp b/engines/wintermute/base/base_sub_frame.cpp index b99ee3a4d8..490a9945db 100644 --- a/engines/wintermute/base/base_sub_frame.cpp +++ b/engines/wintermute/base/base_sub_frame.cpp @@ -34,7 +34,6 @@ #include "engines/wintermute/base/base_surface_storage.h" #include "engines/wintermute/base/base_game.h" #include "engines/wintermute/base/base_engine.h" -#include "engines/wintermute/platform_osystem.h" #include "engines/wintermute/base/gfx/base_renderer.h" #include "engines/wintermute/base/scriptables/script_value.h" #include "engines/wintermute/base/scriptables/script_stack.h" @@ -219,7 +218,7 @@ bool BaseSubFrame::loadBuffer(char *buffer, int lifeTime, bool keepLoaded) { Rect32 BaseSubFrame::getRect() { if (_wantsDefaultRect && _surface) { - BasePlatform::setRect(&_rect, 0, 0, _surface->getWidth(), _surface->getHeight()); + _rect.setRect(0, 0, _surface->getWidth(), _surface->getHeight()); _wantsDefaultRect = false; } return _rect; @@ -294,11 +293,10 @@ bool BaseSubFrame::getBoundingRect(Rect32 *rect, int x, int y, float scaleX, flo float ratioX = scaleX / 100.0f; float ratioY = scaleY / 100.0f; - BasePlatform::setRect(rect, - (int)(x - _hotspotX * ratioX), - (int)(y - _hotspotY * ratioY), - (int)(x - _hotspotX * ratioX + (getRect().right - getRect().left) * ratioX), - (int)(y - _hotspotY * ratioY + (getRect().bottom - getRect().top) * ratioY)); + rect->setRect((int)(x - _hotspotX * ratioX), + (int)(y - _hotspotY * ratioY), + (int)(x - _hotspotX * ratioX + (getRect().right - getRect().left) * ratioX), + (int)(y - _hotspotY * ratioY + (getRect().bottom - getRect().top) * ratioY)); return true; } @@ -320,7 +318,7 @@ bool BaseSubFrame::saveAsText(BaseDynamicBuffer *buffer, int indent, bool comple Rect32 rect; rect.setEmpty(); if (_surface) { - BasePlatform::setRect(&rect, 0, 0, _surface->getWidth(), _surface->getHeight()); + rect.setRect(0, 0, _surface->getWidth(), _surface->getHeight()); } if (!(rect == getRect())) { buffer->putTextIndent(indent + 2, "RECT { %d,%d,%d,%d }\n", getRect().left, getRect().top, getRect().right, getRect().bottom); |