summaryrefslogtreecommitdiff
path: root/src/render/sdl2graphics.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-11-23 22:38:33 +0300
committerAndrei Karas <akaras@inbox.ru>2013-11-23 22:38:33 +0300
commitc5327f3b1d10171ff2a97546ea49e350b1725c24 (patch)
tree2cd1ada4c5db1ad3452bcf7aca9c424c0ed848d2 /src/render/sdl2graphics.cpp
parentdb1e60556c72b1b87ff2a384c556ccca724c46d6 (diff)
parent6bed768bc416eed0212b62e70731d2c40cd1b69b (diff)
downloadplus-c5327f3b1d10171ff2a97546ea49e350b1725c24.tar.gz
plus-c5327f3b1d10171ff2a97546ea49e350b1725c24.tar.bz2
plus-c5327f3b1d10171ff2a97546ea49e350b1725c24.tar.xz
plus-c5327f3b1d10171ff2a97546ea49e350b1725c24.zip
Merge branch 'master' into stable
Diffstat (limited to 'src/render/sdl2graphics.cpp')
-rw-r--r--src/render/sdl2graphics.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/render/sdl2graphics.cpp b/src/render/sdl2graphics.cpp
index 76cde005a..ff8da65c9 100644
--- a/src/render/sdl2graphics.cpp
+++ b/src/render/sdl2graphics.cpp
@@ -126,7 +126,7 @@ bool SDLGraphics::drawImage2(const Image *const image, int srcX, int srcY,
return false;
const gcn::ClipRectangle &top = mClipStack.top();
- if (!top.height)
+ if (!top.width || !top.height)
return false;
const SDL_Rect &bounds = image->mBounds;
@@ -161,7 +161,7 @@ void SDLGraphics::drawImagePattern(const Image *const image,
return;
const gcn::ClipRectangle &top = mClipStack.top();
- if (!top.height)
+ if (!top.width || !top.height)
return;
const SDL_Rect &bounds = image->mBounds;
@@ -212,7 +212,7 @@ void SDLGraphics::drawRescaledImagePattern(const Image *const image,
return;
const gcn::ClipRectangle &top = mClipStack.top();
- if (!top.height)
+ if (!top.width || !top.height)
return;
Image *const tmpImage = image->SDLgetScaledImage(
@@ -264,7 +264,7 @@ void SDLGraphics::calcImagePattern(ImageVertexes* const vert,
return;
const gcn::ClipRectangle &top = mClipStack.top();
- if (!top.height)
+ if (!top.width || !top.height)
return;
const SDL_Rect &bounds = image->mBounds;
@@ -341,7 +341,7 @@ void SDLGraphics::calcTileSDL(ImageVertexes *const vert, int x, int y) const
return;
const gcn::ClipRectangle &top = mClipStack.top();
- if (!top.height)
+ if (!top.width || !top.height)
return;
const Image *const image = vert->image;