Kaydet (Commit) b76f96a5 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

loplugin:implicitboolconversion clean-up

Change-Id: I3c6baec2cec24e23e9bdf78882a69838f10b533c
üst d881bde0
......@@ -105,7 +105,7 @@ private:
sal_uInt8 mcBlueOrIndex;
sal_uInt8 mcGreen;
sal_uInt8 mcRed;
sal_uInt8 mbIndex;
sal_uInt8 mbIndex; // should be bool, but see above warning
public:
......@@ -272,7 +272,7 @@ inline BitmapColor::BitmapColor() :
mcBlueOrIndex ( 0 ),
mcGreen ( 0 ),
mcRed ( 0 ),
mbIndex ( false )
mbIndex ( sal_uInt8(false) )
{
}
......@@ -280,7 +280,7 @@ inline BitmapColor::BitmapColor( sal_uInt8 cRed, sal_uInt8 cGreen, sal_uInt8 cBl
mcBlueOrIndex ( cBlue ),
mcGreen ( cGreen ),
mcRed ( cRed ),
mbIndex ( false )
mbIndex ( sal_uInt8(false) )
{
}
......@@ -296,7 +296,7 @@ inline BitmapColor::BitmapColor( const Color& rColor ) :
mcBlueOrIndex ( rColor.GetBlue() ),
mcGreen ( rColor.GetGreen() ),
mcRed ( rColor.GetRed() ),
mbIndex ( 0 )
mbIndex ( sal_uInt8(false) )
{
}
......@@ -304,14 +304,14 @@ inline BitmapColor::BitmapColor( sal_uInt8 cIndex ) :
mcBlueOrIndex ( cIndex ),
mcGreen ( 0 ),
mcRed ( 0 ),
mbIndex ( true )
mbIndex ( sal_uInt8(true) )
{
}
inline bool BitmapColor::operator==( const BitmapColor& rBitmapColor ) const
{
return( ( mcBlueOrIndex == rBitmapColor.mcBlueOrIndex ) &&
( mbIndex ? rBitmapColor.mbIndex :
( mbIndex ? bool(rBitmapColor.mbIndex) :
( mcGreen == rBitmapColor.mcGreen && mcRed == rBitmapColor.mcRed ) ) );
}
......
......@@ -433,7 +433,7 @@ void ImplReadExtendedPolyPolygonAction(SvStream& rIStm, tools::PolyPolygon& rPol
ReadPair( rIStm , aCandidate[b] );
}
sal_uInt8 bHasFlags(false);
sal_uInt8 bHasFlags(int(false));
rIStm.ReadUChar( bHasFlags );
if(bHasFlags)
......
......@@ -1564,14 +1564,16 @@ bool ReadDIBBitmapEx(
if(bRetval)
{
sal_uInt8 bTransparent(false);
sal_uInt8 transparent = TRANSPARENT_NONE;
rIStm.ReadUChar( bTransparent );
rIStm.ReadUChar( transparent );
bRetval = !rIStm.GetError();
if(bRetval)
{
if((sal_uInt8)TRANSPARENT_BITMAP == bTransparent)
switch (transparent)
{
case TRANSPARENT_BITMAP:
{
Bitmap aMask;
......@@ -1596,8 +1598,9 @@ bool ReadDIBBitmapEx(
}
}
}
break;
}
else if((sal_uInt8)TRANSPARENT_COLOR == bTransparent)
case TRANSPARENT_COLOR:
{
Color aTransparentColor;
......@@ -1608,6 +1611,8 @@ bool ReadDIBBitmapEx(
{
rTarget = BitmapEx(aBmp, aTransparentColor);
}
break;
}
}
}
}
......
......@@ -637,7 +637,7 @@ void Font::Merge( const vcl::Font& rFont )
SetOrientation( rFont.GetOrientation() );
SetVertical( rFont.IsVertical() );
SetEmphasisMark( rFont.GetEmphasisMark() );
SetKerning( rFont.IsKerning() );
SetKerning( rFont.IsKerning() ? KERNING_FONTSPECIFIC : 0 );
SetOutline( rFont.IsOutline() );
SetShadow( rFont.IsShadow() );
SetRelief( rFont.GetRelief() );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment