aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorD G Turner2019-09-15 23:24:33 +0100
committerD G Turner2019-09-15 23:24:33 +0100
commitd83e0df8f0167b6fa8583cf22dfe8b104d47436f (patch)
tree7807d368091a39061b608c8ab914dc8f00042ed6
parent8da29e1b89b60d34a0ff2b8898fc2149e608ea0c (diff)
downloadscummvm-rg350-d83e0df8f0167b6fa8583cf22dfe8b104d47436f.tar.gz
scummvm-rg350-d83e0df8f0167b6fa8583cf22dfe8b104d47436f.tar.bz2
scummvm-rg350-d83e0df8f0167b6fa8583cf22dfe8b104d47436f.zip
GRAPHICS: Fix MSVC Warning in Nine Patch
-rw-r--r--graphics/nine_patch.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/graphics/nine_patch.cpp b/graphics/nine_patch.cpp
index ce82fff61e..d521df94d1 100644
--- a/graphics/nine_patch.cpp
+++ b/graphics/nine_patch.cpp
@@ -267,6 +267,8 @@ NinePatchBitmap::~NinePatchBitmap() {
}
void NinePatchBitmap::drawRegions(Graphics::Surface &target, int dx, int dy, int dw, int dh) {
+ uint color = TS_ARGB(255, 255, 255, 255);
+
/* draw each region */
for (uint i = 0; i < _v._m.size(); ++i) {
for (uint j = 0; j < _h._m.size(); ++j) {
@@ -274,7 +276,7 @@ void NinePatchBitmap::drawRegions(Graphics::Surface &target, int dx, int dy, int
_h._m[j]->offset + _h._m[j]->length, _v._m[i]->offset + _v._m[i]->length);
_bmp->blit(target, dx + _h._m[j]->dest_offset, dy + _v._m[i]->dest_offset,
- Graphics::FLIP_NONE, &r, TS_ARGB(255, 255, 255, 255),
+ Graphics::FLIP_NONE, &r, color,
_h._m[j]->dest_length, _v._m[i]->dest_length);
}
}
@@ -302,6 +304,8 @@ void NinePatchBitmap::blitClip(Graphics::Surface &target, Common::Rect clip, int
_cached_dh = dh;
}
+ uint color = TS_ARGB(255, 255, 255, 255);
+
/* draw each region */
for (uint i = 0; i < _v._m.size(); ++i) {
for (uint j = 0; j < _h._m.size(); ++j) {
@@ -309,7 +313,7 @@ void NinePatchBitmap::blitClip(Graphics::Surface &target, Common::Rect clip, int
_h._m[j]->offset + _h._m[j]->length, _v._m[i]->offset + _v._m[i]->length);
_bmp->blitClip(target, clip, dx + _h._m[j]->dest_offset, dy + _v._m[i]->dest_offset,
- Graphics::FLIP_NONE, &r, TS_ARGB(255, 255, 255, 255),
+ Graphics::FLIP_NONE, &r, color,
_h._m[j]->dest_length, _v._m[i]->dest_length);
}
}