diff options
author | Pierre-André Jacquod <pjacquod@alumni.ethz.ch> | 2011-09-23 16:36:15 +0200 |
---|---|---|
committer | Pierre-André Jacquod <pjacquod@alumni.ethz.ch> | 2011-09-26 22:02:40 +0200 |
commit | a267506512cdebae2272009a07637345f719bfa5 (patch) | |
tree | 6ce858a256b93dcb3cede7666914ee80a0f33f50 /vcl | |
parent | bd4200dc20f6b26f71a358cf219f61d579689f31 (diff) |
cppcheck: reduce scope of var in vcl outdev2.cxx
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/gdi/outdev2.cxx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/vcl/source/gdi/outdev2.cxx b/vcl/source/gdi/outdev2.cxx index d1a76a9f085b..ea57043d61c2 100644 --- a/vcl/source/gdi/outdev2.cxx +++ b/vcl/source/gdi/outdev2.cxx @@ -1639,7 +1639,7 @@ Bitmap OutputDevice::ImplBlendWithAlpha( Bitmap aBmp, { BitmapColor aDstCol,aSrcCol; Bitmap res; - int nX, nOutX, nY, nOutY; + int nX, nY; OSL_ENSURE(mpAlphaVDev, "ImplBlendWithAlpha(): call me only with valid alpha VDev!" ); @@ -1659,10 +1659,13 @@ Bitmap OutputDevice::ImplBlendWithAlpha( Bitmap aBmp, if( pB && pP && pA && pW && pAlphaW ) { + int nOutY; + for( nY = 0, nOutY = nOffY; nY < nDstHeight; nY++, nOutY++ ) { const long nMapY = pMapY[ nY ]; const long nModY = ( nOutY & 0x0FL ) << 4L; + int nOutX; for( nX = 0, nOutX = nOffX; nX < nDstWidth; nX++, nOutX++ ) { @@ -1765,7 +1768,7 @@ Bitmap OutputDevice::ImplBlend( Bitmap aBmp, { BitmapColor aDstCol; Bitmap res; - int nX, nOutX, nY, nOutY; + int nX, nY; if( GetBitCount() <= 8 ) { @@ -1776,10 +1779,13 @@ Bitmap OutputDevice::ImplBlend( Bitmap aBmp, if( pB && pP && pA && pW ) { + int nOutY; + for( nY = 0, nOutY = nOffY; nY < nDstHeight; nY++, nOutY++ ) { const long nMapY = pMapY[ nY ]; const long nModY = ( nOutY & 0x0FL ) << 4L; + int nOutX; for( nX = 0, nOutX = nOffX; nX < nDstWidth; nX++, nOutX++ ) { |