summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-11-16 14:05:25 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-16 14:31:38 +0100
commit890afecb45bfcd2e53599974fbcf61fffd8f8a7b (patch)
tree9233bafbcfae88e93d387e501e3195aa3e98d2f4 /filter
parentfaa63cd14c1d360d0e4eedb64cd879aa1229fa60 (diff)
loplugin:buriedassign in dbaccess..oox
Change-Id: Ic0ca695a1d9d05418213475a68e233953136cc8e Reviewed-on: https://gerrit.libreoffice.org/63468 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'filter')
-rw-r--r--filter/source/graphicfilter/egif/giflzwc.cxx3
-rw-r--r--filter/source/graphicfilter/eps/eps.cxx3
-rw-r--r--filter/source/graphicfilter/etiff/etiff.cxx3
-rw-r--r--filter/source/graphicfilter/icgm/class5.cxx21
-rw-r--r--filter/source/graphicfilter/idxf/dxf2mtf.cxx12
-rw-r--r--filter/source/msfilter/mstoolbar.cxx5
-rw-r--r--filter/source/svg/svgfontexport.cxx3
-rw-r--r--filter/source/svg/svgwriter.cxx13
8 files changed, 40 insertions, 23 deletions
diff --git a/filter/source/graphicfilter/egif/giflzwc.cxx b/filter/source/graphicfilter/egif/giflzwc.cxx
index 8b1950e526a2..3dc595a0923b 100644
--- a/filter/source/graphicfilter/egif/giflzwc.cxx
+++ b/filter/source/graphicfilter/egif/giflzwc.cxx
@@ -145,7 +145,8 @@ void GIFLZWCompressor::StartCompression( SvStream& rGIF, sal_uInt16 nPixelSize )
for (i=0; i<4096; i++)
{
pTable[i].pBrother = pTable[i].pFirstChild = nullptr;
- pTable[i].nValue = static_cast<sal_uInt8>( pTable[i].nCode = i );
+ pTable[i].nCode = i;
+ pTable[i].nValue = static_cast<sal_uInt8>( i );
}
pPrefix = nullptr;
diff --git a/filter/source/graphicfilter/eps/eps.cxx b/filter/source/graphicfilter/eps/eps.cxx
index c6a14bfeab0e..dac781d7fe87 100644
--- a/filter/source/graphicfilter/eps/eps.cxx
+++ b/filter/source/graphicfilter/eps/eps.cxx
@@ -2507,7 +2507,8 @@ void PSWriter::StartCompression()
for ( i = 0; i < 4096; i++ )
{
pTable[ i ].pBrother = pTable[ i ].pFirstChild = nullptr;
- pTable[ i ].nValue = static_cast<sal_uInt8>( pTable[ i ].nCode = i );
+ pTable[ i ].nCode = i;
+ pTable[ i ].nValue = static_cast<sal_uInt8>( i );
}
pPrefix = nullptr;
WriteBits( nClearCode, nCodeSize );
diff --git a/filter/source/graphicfilter/etiff/etiff.cxx b/filter/source/graphicfilter/etiff/etiff.cxx
index 2c95f2c5712d..badcfff9f932 100644
--- a/filter/source/graphicfilter/etiff/etiff.cxx
+++ b/filter/source/graphicfilter/etiff/etiff.cxx
@@ -503,7 +503,8 @@ void TIFFWriter::StartCompression()
for ( i = 0; i < 4096; i++)
{
pTable[ i ].pBrother = pTable[ i ].pFirstChild = nullptr;
- pTable[ i ].nValue = static_cast<sal_uInt8>( pTable[ i ].nCode = i );
+ pTable[ i ].nCode = i;
+ pTable[ i ].nValue = static_cast<sal_uInt8>( i );
}
pPrefix = nullptr;
diff --git a/filter/source/graphicfilter/icgm/class5.cxx b/filter/source/graphicfilter/icgm/class5.cxx
index 15bd16bf4778..c74aee3497b4 100644
--- a/filter/source/graphicfilter/icgm/class5.cxx
+++ b/filter/source/graphicfilter/icgm/class5.cxx
@@ -53,9 +53,10 @@ void CGM::ImplDoClass5()
else
nWidth = static_cast<sal_uInt32>(ImplGetFloat( pElement->eRealPrecision, pElement->nRealSize )) * 25; // scaling in 1/4 mm
- ( pElement->nAspectSourceFlags & ASF_LINEWIDTH )
- ? pElement->pLineBundle->nLineWidth = nWidth
- : pElement->aLineBundle.nLineWidth = nWidth;
+ if ( pElement->nAspectSourceFlags & ASF_LINEWIDTH )
+ pElement->pLineBundle->nLineWidth = nWidth;
+ else
+ pElement->aLineBundle.nLineWidth = nWidth;
}
break;
case 0x04 : /*Line Color*/
@@ -90,9 +91,10 @@ void CGM::ImplDoClass5()
}
else
nWidth = static_cast<sal_uInt32>(ImplGetFloat( pElement->eRealPrecision, pElement->nRealSize )) * 25;
- ( pElement->nAspectSourceFlags & ASF_MARKERSIZE )
- ? pElement->pMarkerBundle->nMarkerSize = nWidth
- : pElement->aMarkerBundle.nMarkerSize = nWidth;
+ if ( pElement->nAspectSourceFlags & ASF_MARKERSIZE )
+ pElement->pMarkerBundle->nMarkerSize = nWidth;
+ else
+ pElement->aMarkerBundle.nMarkerSize = nWidth;
}
break;
case 0x08 : /*Marker Color*/
@@ -268,9 +270,10 @@ void CGM::ImplDoClass5()
}
else
nWidth = static_cast<sal_uInt32>(ImplGetFloat( pElement->eRealPrecision, pElement->nRealSize )) * 25;
- ( pElement->nAspectSourceFlags & ASF_EDGEWIDTH )
- ? pElement->pEdgeBundle->nEdgeWidth = nWidth
- : pElement->aEdgeBundle.nEdgeWidth = nWidth;
+ if ( pElement->nAspectSourceFlags & ASF_EDGEWIDTH )
+ pElement->pEdgeBundle->nEdgeWidth = nWidth;
+ else
+ pElement->aEdgeBundle.nEdgeWidth = nWidth;
}
break;
case 0x1d : /*Edge Color*/
diff --git a/filter/source/graphicfilter/idxf/dxf2mtf.cxx b/filter/source/graphicfilter/idxf/dxf2mtf.cxx
index e5f312b743e0..1f70f450bda2 100644
--- a/filter/source/graphicfilter/idxf/dxf2mtf.cxx
+++ b/filter/source/graphicfilter/idxf/dxf2mtf.cxx
@@ -154,11 +154,13 @@ bool DXF2GDIMetaFile::SetLineAttribute(const DXFBasicEntity & rE)
aColor=ConvertColor(static_cast<sal_uInt8>(nColor));
if (aActLineColor!=aColor) {
- pVirDev->SetLineColor( aActLineColor = aColor );
+ aActLineColor = aColor;
+ pVirDev->SetLineColor( aActLineColor );
}
if (aActFillColor!=COL_TRANSPARENT) {
- pVirDev->SetFillColor(aActFillColor = COL_TRANSPARENT);
+ aActFillColor = COL_TRANSPARENT;
+ pVirDev->SetFillColor(aActFillColor);
}
return true;
}
@@ -174,11 +176,13 @@ bool DXF2GDIMetaFile::SetAreaAttribute(const DXFBasicEntity & rE)
aColor=ConvertColor(static_cast<sal_uInt8>(nColor));
if (aActLineColor!=aColor) {
- pVirDev->SetLineColor( aActLineColor = aColor );
+ aActLineColor = aColor;
+ pVirDev->SetLineColor( aActLineColor );
}
if ( aActFillColor == COL_TRANSPARENT || aActFillColor != aColor) {
- pVirDev->SetFillColor( aActFillColor = aColor );
+ aActFillColor = aColor;
+ pVirDev->SetFillColor( aActFillColor );
}
return true;
}
diff --git a/filter/source/msfilter/mstoolbar.cxx b/filter/source/msfilter/mstoolbar.cxx
index 5d985e60cc96..e6e085a06dce 100644
--- a/filter/source/msfilter/mstoolbar.cxx
+++ b/filter/source/msfilter/mstoolbar.cxx
@@ -336,7 +336,10 @@ void TBCData::ImportToolBarControl( CustomToolBarImportHelper& helper, std::vect
TBCMenuSpecific* pMenu = getMenuSpecific();
if ( pMenu )
- aProp.Value <<= sMenuBar += pMenu->Name(); // name of popup
+ {
+ sMenuBar += pMenu->Name();
+ aProp.Value <<= sMenuBar; // name of popup
+ }
nStyle |= ui::ItemStyle::DROP_DOWN;
props.push_back( aProp );
}
diff --git a/filter/source/svg/svgfontexport.cxx b/filter/source/svg/svgfontexport.cxx
index 69dbb720c2da..50de3e5fd89f 100644
--- a/filter/source/svg/svgfontexport.cxx
+++ b/filter/source/svg/svgfontexport.cxx
@@ -189,7 +189,8 @@ void SVGFontExport::implEmbedFont( const vcl::Font& rFont )
pVDev->SetMapMode(MapMode(MapUnit::Map100thMM));
pVDev->SetFont( aFont );
- mrExport.AddAttribute( XML_NAMESPACE_NONE, "id", aCurIdStr += OUString::number( ++mnCurFontId ) );
+ aCurIdStr += OUString::number( ++mnCurFontId );
+ mrExport.AddAttribute( XML_NAMESPACE_NONE, "id", aCurIdStr );
mrExport.AddAttribute( XML_NAMESPACE_NONE, "horiz-adv-x", aUnitsPerEM );
{
diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index 9565383dbb5d..1030c041ff1c 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -224,8 +224,8 @@ void SVGAttributeWriter::AddGradientDef( const tools::Rectangle& rObjRect, const
aEndColor.SetGreen( static_cast<sal_uInt8>( ( aEndColor.GetGreen() * rGradient.GetEndIntensity() ) / 100 ) );
aEndColor.SetBlue( static_cast<sal_uInt8>( ( aEndColor.GetBlue() * rGradient.GetEndIntensity() ) / 100 ) );
- mrExport.AddAttribute( XML_NAMESPACE_NONE, aXMLAttrId,
- ( rGradientId = "Gradient_" ) += OUString::number( nCurGradientId++ ) );
+ rGradientId = "Gradient_" + OUString::number( nCurGradientId++ );
+ mrExport.AddAttribute( XML_NAMESPACE_NONE, aXMLAttrId, rGradientId );
{
std::unique_ptr< SvXMLElementExport > apGradient;
@@ -3705,11 +3705,14 @@ void SVGActionWriter::WriteMetaFile( const Point& rPos100thmm,
mpVDev->Push();
Size aSize( OutputDevice::LogicToLogic(rSize100thmm, MapMode(MapUnit::Map100thMM), aMapMode) );
- aMapMode.SetScaleX( aFractionX *= Fraction( aSize.Width(), aPrefSize.Width() ) );
- aMapMode.SetScaleY( aFractionY *= Fraction( aSize.Height(), aPrefSize.Height() ) );
+ aFractionX *= Fraction( aSize.Width(), aPrefSize.Width() );
+ aMapMode.SetScaleX( aFractionX );
+ aFractionY *= Fraction( aSize.Height(), aPrefSize.Height() );
+ aMapMode.SetScaleY( aFractionY );
Point aOffset( OutputDevice::LogicToLogic(rPos100thmm, MapMode(MapUnit::Map100thMM), aMapMode ) );
- aMapMode.SetOrigin( aOffset += aMapMode.GetOrigin() );
+ aOffset += aMapMode.GetOrigin();
+ aMapMode.SetOrigin( aOffset );
mpVDev->SetMapMode( aMapMode );