aboutsummaryrefslogtreecommitdiff
path: root/gui/widget.cpp
diff options
context:
space:
mode:
authorBastien Bouclet2019-08-27 08:07:14 +0200
committerBastien Bouclet2019-10-07 21:47:42 +0200
commit1d764bd787a20ab4b8d6edd79d3bc7db459e3eb0 (patch)
treeb6e201244aabf6c87b40905cc1097c0955c73991 /gui/widget.cpp
parentb87ebdce2101a9943f727168526fe89725ebe759 (diff)
downloadscummvm-rg350-1d764bd787a20ab4b8d6edd79d3bc7db459e3eb0.tar.gz
scummvm-rg350-1d764bd787a20ab4b8d6edd79d3bc7db459e3eb0.tar.bz2
scummvm-rg350-1d764bd787a20ab4b8d6edd79d3bc7db459e3eb0.zip
GRAPHICS: Vector renderer clipping rect related cleanups
Selecting whether a clipping variant of a draw call needs to be used is no longer the responsibility to the caller. The clipping rect is now part of the state of the renderer. Also fix some of the draw calls to better apply the clipping rect.
Diffstat (limited to 'gui/widget.cpp')
-rw-r--r--gui/widget.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/gui/widget.cpp b/gui/widget.cpp
index 3e372828e1..750fa4e80f 100644
--- a/gui/widget.cpp
+++ b/gui/widget.cpp
@@ -482,7 +482,7 @@ void PicButtonWidget::drawWidget() {
const int x = _x + (_w - gfx->w) / 2;
const int y = _y + (_h - gfx->h) / 2;
- g_gui.theme()->drawSurface(Common::Rect(x, y, x + gfx->w, y + gfx->h), *gfx, _transparency);
+ g_gui.theme()->drawSurface(Common::Point(x, y), *gfx, _transparency);
}
}
@@ -733,7 +733,7 @@ void GraphicsWidget::drawWidget() {
const int x = _x + (_w - _gfx.w) / 2;
const int y = _y + (_h - _gfx.h) / 2;
- g_gui.theme()->drawSurface(Common::Rect(x, y, x + _gfx.w, y + _gfx.h), _gfx, _transparency);
+ g_gui.theme()->drawSurface(Common::Point(x, y), _gfx, _transparency);
}
}