diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-01-09 20:46:39 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-01-09 21:02:24 +0000 |
commit | 9921bae92ebfe1f1372fb4158a51a6f70ea738bd (patch) | |
tree | c4b72052ea14b05847b97fbae97c21e9f9405b6e /vcl | |
parent | 4cf87913dbb3fdf336e518e8cae9b4bff56edf6a (diff) |
cppcheck: truncLongCastAssignment
Change-Id: I55f684c0afb8b0d4ab4b749084a3ab7b66201bda
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/gdi/bitmap.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vcl/source/gdi/bitmap.cxx b/vcl/source/gdi/bitmap.cxx index 6b675edc4f5e..d0f266626256 100644 --- a/vcl/source/gdi/bitmap.cxx +++ b/vcl/source/gdi/bitmap.cxx @@ -809,7 +809,7 @@ bool Bitmap::CopyPixel( const Rectangle& rRectDst, if( nSrcBitCount > nDstBitCount ) { - long nNextIndex = 0L; + int nNextIndex = 0; if( ( nSrcBitCount == 24 ) && ( nDstBitCount < 24 ) ) Convert( BMP_CONVERSION_24BIT ); @@ -831,16 +831,16 @@ bool Bitmap::CopyPixel( const Rectangle& rRectDst, if( pSrcAcc && pDstAcc ) { - const long nSrcCount = pDstAcc->GetPaletteEntryCount(); - const long nDstCount = 1 << nDstBitCount; + const int nSrcCount = pDstAcc->GetPaletteEntryCount(); + const int nDstCount = 1 << nDstBitCount; - for( long i = 0L; ( i < nSrcCount ) && ( nNextIndex < nSrcCount ); i++ ) + for (int i = 0; ( i < nSrcCount ) && ( nNextIndex < nSrcCount ); ++i) { const BitmapColor& rSrcCol = pSrcAcc->GetPaletteColor( (sal_uInt16) i ); bool bFound = false; - for( long j = 0L; j < nDstCount; j++ ) + for (int j = 0; j < nDstCount; ++j) { if( rSrcCol == pDstAcc->GetPaletteColor( (sal_uInt16) j ) ) { |