summaryrefslogtreecommitdiff
path: root/src/blitter
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-08-20 10:23:39 +0000
committerrubidium <rubidium@openttd.org>2009-08-20 10:23:39 +0000
commit7fb95e2c2b2f84ecf9b5d5d2f02b147d1ad7cb3d (patch)
treefeb24d4a4f522305f7df61aaf26c499eb38c6b6c /src/blitter
parent0188ebad5649d4c698245a2fef9039e6155b5f22 (diff)
downloadopenttd-7fb95e2c2b2f84ecf9b5d5d2f02b147d1ad7cb3d.tar.xz
(svn r17228) -Codechange: some coding style fixes
Diffstat (limited to 'src/blitter')
-rw-r--r--src/blitter/32bpp_anim.cpp14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/blitter/32bpp_anim.cpp b/src/blitter/32bpp_anim.cpp
index 1c72a1382..2ff9b536a 100644
--- a/src/blitter/32bpp_anim.cpp
+++ b/src/blitter/32bpp_anim.cpp
@@ -363,8 +363,11 @@ void Blitter_32bppAnim::ScrollBuffer(void *video, int &left, int &top, int &widt
src = dst - scroll_y * this->anim_buf_width;
/* Adjust left & width */
- if (scroll_x >= 0) dst += scroll_x;
- else src -= scroll_x;
+ if (scroll_x >= 0) {
+ dst += scroll_x;
+ } else {
+ src -= scroll_x;
+ }
uint tw = width + (scroll_x >= 0 ? -scroll_x : scroll_x);
uint th = height - scroll_y;
@@ -379,8 +382,11 @@ void Blitter_32bppAnim::ScrollBuffer(void *video, int &left, int &top, int &widt
src = dst - scroll_y * this->anim_buf_width;
/* Adjust left & width */
- if (scroll_x >= 0) dst += scroll_x;
- else src -= scroll_x;
+ if (scroll_x >= 0) {
+ dst += scroll_x;
+ } else {
+ src -= scroll_x;
+ }
/* the y-displacement may be 0 therefore we have to use memmove,
* because source and destination may overlap */