summaryrefslogtreecommitdiff
path: root/vcl/source/gdi
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-03-23 09:47:49 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-03-23 09:48:10 +0000
commited76d1d3504c92bff6bb3e6417e4440572fcd959 (patch)
tree6d06b4a20bef5acf0c1a4118685f09acdd27fbb7 /vcl/source/gdi
parenta61c4ae9cef23a53ea88f957e090bd5ee9b28ca6 (diff)
loplugins:redundantcast teach it about c-style typedef casts
Change-Id: I1ac11a2481c0f4d8be1e1fd7c7637ac0ece3d65c Reviewed-on: https://gerrit.libreoffice.org/35558 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/gdi')
-rw-r--r--vcl/source/gdi/bitmap.cxx4
-rw-r--r--vcl/source/gdi/dibtools.cxx2
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx4
-rw-r--r--vcl/source/gdi/pdfwriter_impl2.cxx2
-rw-r--r--vcl/source/gdi/pngread.cxx2
5 files changed, 7 insertions, 7 deletions
diff --git a/vcl/source/gdi/bitmap.cxx b/vcl/source/gdi/bitmap.cxx
index 2931f7c1d8dc..ca040df7d384 100644
--- a/vcl/source/gdi/bitmap.cxx
+++ b/vcl/source/gdi/bitmap.cxx
@@ -1448,7 +1448,7 @@ bool Bitmap::Replace( const Bitmap& rMask, const Color& rReplaceColor )
// Hurray, we do have an unused entry
if( !pFlags[ i ] )
{
- pAcc->SetPaletteColor( (sal_uInt16) i, rReplaceColor );
+ pAcc->SetPaletteColor( i, rReplaceColor );
aReplace = BitmapColor( (sal_uInt8) i );
}
}
@@ -1642,7 +1642,7 @@ bool Bitmap::Replace( const Color* pSearchColors, const Color* pReplaceColors,
pMinG[ i ] <= rCol.GetGreen() && pMaxG[ i ] >= rCol.GetGreen() &&
pMinB[ i ] <= rCol.GetBlue() && pMaxB[ i ] >= rCol.GetBlue() )
{
- pAcc->SetPaletteColor( (sal_uInt16)nEntry, pReplaceColors[ i ] );
+ pAcc->SetPaletteColor( nEntry, pReplaceColors[ i ] );
break;
}
}
diff --git a/vcl/source/gdi/dibtools.cxx b/vcl/source/gdi/dibtools.cxx
index 1559a6ac189f..1f2b0a63e26d 100644
--- a/vcl/source/gdi/dibtools.cxx
+++ b/vcl/source/gdi/dibtools.cxx
@@ -1350,7 +1350,7 @@ bool ImplWriteDIBBits(SvStream& rOStm, BitmapReadAccess& rAcc, BitmapReadAccess*
if(bWriteAlpha)
{
- *pTmp++ = (sal_uInt8)0xff - (sal_uInt8)pAccAlpha->GetPixelIndex( nY, nX );
+ *pTmp++ = (sal_uInt8)0xff - pAccAlpha->GetPixelIndex( nY, nX );
}
}
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index ef7a11140b5e..a3d38b224340 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -3334,7 +3334,7 @@ bool PDFWriterImpl::emitFonts()
aLine.append( nFontStream );
aLine.append( " 0 obj\n"
"<</Length " );
- aLine.append( (sal_Int32)nStreamLengthObject );
+ aLine.append( nStreamLengthObject );
if (!g_bDebugDisableCompression)
aLine.append( " 0 R"
"/Filter/FlateDecode"
@@ -7755,7 +7755,7 @@ sal_Int32 PDFWriterImpl::emitDocumentMetadata()
aMetadataObj.append( "<</Type/Metadata/Subtype/XML/Length " );
- aMetadataObj.append( (sal_Int32) aMetadataStream.getLength() );
+ aMetadataObj.append( aMetadataStream.getLength() );
aMetadataObj.append( ">>\nstream\n" );
if ( !writeBuffer( aMetadataObj.getStr(), aMetadataObj.getLength() ) )
return 0;
diff --git a/vcl/source/gdi/pdfwriter_impl2.cxx b/vcl/source/gdi/pdfwriter_impl2.cxx
index 00120c5eb298..4a6b12e05131 100644
--- a/vcl/source/gdi/pdfwriter_impl2.cxx
+++ b/vcl/source/gdi/pdfwriter_impl2.cxx
@@ -266,7 +266,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa
}
GDIMetaFile aMtf( i_rMtf );
- for( sal_uInt32 i = 0, nCount = aMtf.GetActionSize(); i < (sal_uInt32)nCount; )
+ for( sal_uInt32 i = 0, nCount = aMtf.GetActionSize(); i < nCount; )
{
if ( !i_pOutDevData || !i_pOutDevData->PlaySyncPageAct( m_rOuterFace, i ) )
{
diff --git a/vcl/source/gdi/pngread.cxx b/vcl/source/gdi/pngread.cxx
index 09bbc66b695b..056c337f8565 100644
--- a/vcl/source/gdi/pngread.cxx
+++ b/vcl/source/gdi/pngread.cxx
@@ -711,7 +711,7 @@ bool PNGReaderImpl::ImplReadPalette()
if ( ( ( mnChunkLen % 3 ) == 0 ) && ( ( 0 < nCount ) && ( nCount <= 256 ) ) && mxAcc )
{
mbPalette = true;
- mxAcc->SetPaletteEntryCount( (sal_uInt16) nCount );
+ mxAcc->SetPaletteEntryCount( nCount );
for ( sal_uInt16 i = 0; i < nCount; i++ )
{