summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-02-22 16:41:20 +0200
committerNoel Grandin <noel@peralex.com>2016-02-22 16:41:20 +0200
commitbc9aa454ff63a7aa308b84c0170c48dc5267c040 (patch)
tree152c5b4c85f85e896a627e748c1e8688d4c31457 /filter
parent06f9db0db806378391f321388f2125627dbebf27 (diff)
loplugin:commaoperator in filter/
Change-Id: I88697862bfb160d4d7d257bf425507567deae837
Diffstat (limited to 'filter')
-rw-r--r--filter/source/flash/swfwriter1.cxx3
-rw-r--r--filter/source/graphicfilter/eps/eps.cxx6
-rw-r--r--filter/source/graphicfilter/icgm/cgmtypes.hxx2
-rw-r--r--filter/source/graphicfilter/ipbm/ipbm.cxx3
-rw-r--r--filter/source/graphicfilter/ipcd/ipcd.cxx3
-rw-r--r--filter/source/graphicfilter/itga/itga.cxx5
-rw-r--r--filter/source/msfilter/escherex.cxx3
-rw-r--r--filter/source/msfilter/msdffimp.cxx51
-rw-r--r--filter/source/msfilter/svdfppt.cxx21
-rw-r--r--filter/source/svg/svgexport.cxx18
-rw-r--r--filter/source/svg/svgwriter.cxx6
-rw-r--r--filter/source/xsltdialog/typedetectionexport.cxx6
12 files changed, 91 insertions, 36 deletions
diff --git a/filter/source/flash/swfwriter1.cxx b/filter/source/flash/swfwriter1.cxx
index cdb956d57a87..0bf5acaa0fe5 100644
--- a/filter/source/flash/swfwriter1.cxx
+++ b/filter/source/flash/swfwriter1.cxx
@@ -1549,7 +1549,8 @@ void Writer::Impl_writeActions( const GDIMetaFile& rMtf )
aSrcPt.Y() = FRound( aSrcPt.Y() * fScaleY );
}
- nMoveX = aDestPt.X() - aSrcPt.X(), nMoveY = aDestPt.Y() - aSrcPt.Y();
+ nMoveX = aDestPt.X() - aSrcPt.X();
+ nMoveY = aDestPt.Y() - aSrcPt.Y();
if( nMoveX || nMoveY )
aTmpMtf.Move( nMoveX, nMoveY );
diff --git a/filter/source/graphicfilter/eps/eps.cxx b/filter/source/graphicfilter/eps/eps.cxx
index aaa5fd0e1dfa..0704a13f4100 100644
--- a/filter/source/graphicfilter/eps/eps.cxx
+++ b/filter/source/graphicfilter/eps/eps.cxx
@@ -1208,10 +1208,12 @@ void PSWriter::ImplWriteActions( const GDIMetaFile& rMtf, VirtualDevice& rVDev )
if( fScaleX != 1.0 || fScaleY != 1.0 )
{
aTmpMtf.Scale( fScaleX, fScaleY );
- aSrcPt.X() = FRound( aSrcPt.X() * fScaleX ), aSrcPt.Y() = FRound( aSrcPt.Y() * fScaleY );
+ aSrcPt.X() = FRound( aSrcPt.X() * fScaleX );
+ aSrcPt.Y() = FRound( aSrcPt.Y() * fScaleY );
}
- nMoveX = aDestPt.X() - aSrcPt.X(), nMoveY = aDestPt.Y() - aSrcPt.Y();
+ nMoveX = aDestPt.X() - aSrcPt.X();
+ nMoveY = aDestPt.Y() - aSrcPt.Y();
if( nMoveX || nMoveY )
aTmpMtf.Move( nMoveX, nMoveY );
diff --git a/filter/source/graphicfilter/icgm/cgmtypes.hxx b/filter/source/graphicfilter/icgm/cgmtypes.hxx
index b55178812eba..ef560ed4520b 100644
--- a/filter/source/graphicfilter/icgm/cgmtypes.hxx
+++ b/filter/source/graphicfilter/icgm/cgmtypes.hxx
@@ -25,7 +25,7 @@ struct FloatPoint
double X;
double Y;
FloatPoint():X(0), Y(0){};
- FloatPoint( const double& rX, const double& rY ) { X = rX, Y = rY; };
+ FloatPoint( const double& rX, const double& rY ) { X = rX; Y = rY; };
};
struct FloatRect
diff --git a/filter/source/graphicfilter/ipbm/ipbm.cxx b/filter/source/graphicfilter/ipbm/ipbm.cxx
index f77499e43f4d..58d376ed564e 100644
--- a/filter/source/graphicfilter/ipbm/ipbm.cxx
+++ b/filter/source/graphicfilter/ipbm/ipbm.cxx
@@ -132,7 +132,8 @@ bool PBMReader::ReadPBM(Graphic & rGraphic )
if ( mpAcc )
{
- Bitmap::ReleaseAccess( mpAcc ), mpAcc = nullptr;
+ Bitmap::ReleaseAccess( mpAcc );
+ mpAcc = nullptr;
}
if ( mbStatus )
rGraphic = maBmp;
diff --git a/filter/source/graphicfilter/ipcd/ipcd.cxx b/filter/source/graphicfilter/ipcd/ipcd.cxx
index d4568d071a8a..42861ded4cde 100644
--- a/filter/source/graphicfilter/ipcd/ipcd.cxx
+++ b/filter/source/graphicfilter/ipcd/ipcd.cxx
@@ -161,7 +161,8 @@ bool PCDReader::ReadPCD( Graphic & rGraphic, FilterConfigItem* pConfigItem )
ReadImage();
- Bitmap::ReleaseAccess( mpAcc ), mpAcc = nullptr;
+ Bitmap::ReleaseAccess( mpAcc );
+ mpAcc = nullptr;
rGraphic = aBmp;
}
return bStatus;
diff --git a/filter/source/graphicfilter/itga/itga.cxx b/filter/source/graphicfilter/itga/itga.cxx
index 571421d90851..20a90061e4f5 100644
--- a/filter/source/graphicfilter/itga/itga.cxx
+++ b/filter/source/graphicfilter/itga/itga.cxx
@@ -159,7 +159,10 @@ bool TGAReader::ReadTGA(Graphic & rGraphic)
mbStatus = false;
if ( mpAcc )
- Bitmap::ReleaseAccess ( mpAcc), mpAcc = nullptr;
+ {
+ Bitmap::ReleaseAccess ( mpAcc);
+ mpAcc = nullptr;
+ }
if ( mbStatus )
rGraphic = aBitmap;
diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx
index 79108f71b3a3..0dbec5d52a77 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -4453,7 +4453,8 @@ sal_uInt32 EscherGraphicProvider::GetBlibID( SvStream& rPicOutStrm, const OStrin
rPicOutStrm.WriteUInt32( nPos - nAtomSize );
rPicOutStrm.Seek( nPos );
}
- nBlibId = ImplInsertBlib( p_EscherBlibEntry ), p_EscherBlibEntry = nullptr;
+ nBlibId = ImplInsertBlib( p_EscherBlibEntry );
+ p_EscherBlibEntry = nullptr;
}
}
delete p_EscherBlibEntry;
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index b80374e68c17..28068954df93 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -1135,16 +1135,28 @@ void ApplyRectangularGradientAsBitmap( const SvxMSDffManager& rManager, SvStream
if ( fY < fFocusY )
{
if ( fX > fY )
- fDist = fY, fD = fFocusY;
+ {
+ fDist = fY;
+ fD = fFocusY;
+ }
else
- fDist = fX, fD = fFocusX;
+ {
+ fDist = fX;
+ fD = fFocusX;
+ }
}
else
{
if ( fX > ( 1 - fY ) )
- fDist = ( 1 - fY ), fD = 1 - fFocusY;
+ {
+ fDist = 1 - fY;
+ fD = 1 - fFocusY;
+ }
else
- fDist = fX, fD = fFocusX;
+ {
+ fDist = fX;
+ fD = fFocusX;
+ }
}
}
else
@@ -1152,16 +1164,28 @@ void ApplyRectangularGradientAsBitmap( const SvxMSDffManager& rManager, SvStream
if ( fY < fFocusY )
{
if ( ( 1 - fX ) > fY )
- fDist = fY, fD = fFocusY;
+ {
+ fDist = fY;
+ fD = fFocusY;
+ }
else
- fDist = ( 1 - fX ), fD = 1 - fFocusX;
+ {
+ fDist = 1 - fX;
+ fD = 1 - fFocusX;
+ }
}
else
{
if ( ( 1 - fX ) > ( 1 - fY ) )
- fDist = ( 1 - fY ), fD = 1 - fFocusY;
+ {
+ fDist = 1 - fY;
+ fD = 1 - fFocusY;
+ }
else
- fDist = ( 1 - fX ), fD = 1 - fFocusX;
+ {
+ fDist = 1 - fX;
+ fD = 1 - fFocusX;
+ }
}
}
if ( fD != 0.0 )
@@ -2940,7 +2964,8 @@ void DffRecordManager::Consume( SvStream& rIn, bool bAppend, sal_uInt32 nStOfs )
void DffRecordManager::Clear()
{
pCList = static_cast<DffRecordList*>(this);
- delete pNext, pNext = nullptr;
+ delete pNext;
+ pNext = nullptr;
nCurrent = 0;
nCount = 0;
}
@@ -4842,7 +4867,10 @@ Rectangle SvxMSDffManager::GetGlobalChildAnchor( const DffRecordHeader& rHd, SvS
{
sal_Int16 ls, ts, rs, bs;
rSt.ReadInt16( ts ).ReadInt16( ls ).ReadInt16( rs ).ReadInt16( bs ); // the order of coordinates is a bit strange...
- l = ls, t = ts, r = rs, b = bs;
+ l = ls;
+ t = ts;
+ r = rs;
+ b = bs;
}
Scale( l );
Scale( t );
@@ -6320,7 +6348,8 @@ bool SvxMSDffManager::GetBLIPDirect( SvStream& rBLIPStream, Graphic& rData, Rect
aMtfSize100.Height() = height;
// scale to 1/100mm
- aMtfSize100.Width() /= 360, aMtfSize100.Height() /= 360;
+ aMtfSize100.Width() /= 360;
+ aMtfSize100.Height() /= 360;
if ( pVisArea ) // seem that we currently are skipping the visarea position
*pVisArea = Rectangle( Point(), aMtfSize100 );
diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx
index ab232e851482..c778a0abfe46 100644
--- a/filter/source/msfilter/svdfppt.cxx
+++ b/filter/source/msfilter/svdfppt.cxx
@@ -596,7 +596,10 @@ void SdrEscherImport::ProcessClientAnchor2( SvStream& rSt, DffRecordHeader& rHd,
{
sal_Int16 ls, ts, rs, bs;
rSt.ReadInt16( ts ).ReadInt16( ls ).ReadInt16( rs ).ReadInt16( bs ); // the order of coordinates is a bit strange...
- l = ls, t = ts, r = rs, b = bs;
+ l = ls;
+ t = ts;
+ r = rs;
+ b = bs;
}
Scale( l );
Scale( t );
@@ -1972,7 +1975,10 @@ SvMemoryStream* SdrPowerPointImport::ImportExOleObjStg( sal_uInt32 nPersistPtr,
aZCodec.BeginCompression();
aZCodec.Decompress( rStCtrl, *pRet );
if ( !aZCodec.EndCompression() )
- delete pRet, pRet = nullptr;
+ {
+ delete pRet;
+ pRet = nullptr;
+ }
}
}
rStCtrl.Seek( nOldPos );
@@ -6963,7 +6969,7 @@ PPTTextObj::PPTTextObj( SvStream& rIn, SdrPowerPointImport& rSdrPowerPointImport
if ( aString[nCount] == 0x2a )
{
sal_uInt32 nBehind = aString.getLength() - ( nCount + 1 );
- (pSet->maString).clear();
+ pSet->maString.clear();
if ( nBehind )
{
PPTCharPropSet* pNewCPS = new PPTCharPropSet( *pSet );
@@ -6973,7 +6979,8 @@ PPTTextObj::PPTTextObj( SvStream& rIn, SdrPowerPointImport& rSdrPowerPointImport
if ( (*FE)->pField2 )
{
PPTCharPropSet* pNewCPS = new PPTCharPropSet( *pSet );
- pNewCPS->mpFieldItem = (*FE)->pField2, (*FE)->pField2 = nullptr;
+ pNewCPS->mpFieldItem = (*FE)->pField2;
+ (*FE)->pField2 = nullptr;
aCharPropList.insert( aCharPropList.begin() + n + 1, pNewCPS );
pNewCPS = new PPTCharPropSet( *pSet );
@@ -6988,7 +6995,8 @@ PPTTextObj::PPTTextObj( SvStream& rIn, SdrPowerPointImport& rSdrPowerPointImport
}
if ( (*FE)->pField1 )
{
- pSet->mpFieldItem = (*FE)->pField1, (*FE)->pField1 = nullptr;
+ pSet->mpFieldItem = (*FE)->pField1;
+ (*FE)->pField1 = nullptr;
}
else if ( (*FE)->pString )
pSet->maString = *(*FE)->pString;
@@ -7067,7 +7075,8 @@ PPTTextObj::PPTTextObj( SvStream& rIn, SdrPowerPointImport& rSdrPowerPointImport
}
nIdx++;
}
- delete (*FE)->pField1, (*FE)->pField1 = nullptr;
+ delete (*FE)->pField1;
+ (*FE)->pField1 = nullptr;
if ( pBefCPS )
{
diff --git a/filter/source/svg/svgexport.cxx b/filter/source/svg/svgexport.cxx
index 1fcd97046f9d..d66c8aa95649 100644
--- a/filter/source/svg/svgexport.cxx
+++ b/filter/source/svg/svgexport.cxx
@@ -414,7 +414,8 @@ ObjectRepresentation& ObjectRepresentation::operator=( const ObjectRepresentatio
if (this == &rPresentation)
return *this;
mxObject = rPresentation.mxObject;
- delete mpMtf, ( mpMtf = rPresentation.mpMtf ? new GDIMetaFile( *rPresentation.mpMtf ) : nullptr );
+ delete mpMtf;
+ mpMtf = rPresentation.mpMtf ? new GDIMetaFile( *rPresentation.mpMtf ) : nullptr;
return *this;
}
@@ -604,7 +605,8 @@ bool SVGFilter::implExport( const Sequence< PropertyValue >& rDescriptor )
}
catch( ... )
{
- delete mpSVGDoc, mpSVGDoc = nullptr;
+ delete mpSVGDoc;
+ mpSVGDoc = nullptr;
OSL_FAIL( "Exception caught" );
}
@@ -624,10 +626,13 @@ bool SVGFilter::implExport( const Sequence< PropertyValue >& rDescriptor )
}
}
- delete mpSVGWriter, mpSVGWriter = nullptr;
+ delete mpSVGWriter;
+ mpSVGWriter = nullptr;
mpSVGExport = nullptr; // pointed object is released by xSVGExport dtor at the end of this scope
- delete mpSVGFontExport, mpSVGFontExport = nullptr;
- delete mpObjects, mpObjects = nullptr;
+ delete mpSVGFontExport;
+ mpSVGFontExport = nullptr;
+ delete mpObjects;
+ mpObjects = nullptr;
mbPresentation = false;
}
}
@@ -887,7 +892,8 @@ bool SVGFilter::implExportDocument()
implGenerateScript();
}
- delete mpSVGDoc, mpSVGDoc = nullptr;
+ delete mpSVGDoc;
+ mpSVGDoc = nullptr;
bRet = true;
}
}
diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index 6c6ff63ba3b4..2caae96f1c4d 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -2349,10 +2349,12 @@ void SVGActionWriter::ImplWriteMask( GDIMetaFile& rMtf,
if( fScaleX != 1.0 || fScaleY != 1.0 )
{
rMtf.Scale( fScaleX, fScaleY );
- aSrcPt.X() = FRound( aSrcPt.X() * fScaleX ), aSrcPt.Y() = FRound( aSrcPt.Y() * fScaleY );
+ aSrcPt.X() = FRound( aSrcPt.X() * fScaleX );
+ aSrcPt.Y() = FRound( aSrcPt.Y() * fScaleY );
}
- nMoveX = rDestPt.X() - aSrcPt.X(), nMoveY = rDestPt.Y() - aSrcPt.Y();
+ nMoveX = rDestPt.X() - aSrcPt.X();
+ nMoveY = rDestPt.Y() - aSrcPt.Y();
if( nMoveX || nMoveY )
rMtf.Move( nMoveX, nMoveY );
diff --git a/filter/source/xsltdialog/typedetectionexport.cxx b/filter/source/xsltdialog/typedetectionexport.cxx
index eef44cf08101..bb307e14910a 100644
--- a/filter/source/xsltdialog/typedetectionexport.cxx
+++ b/filter/source/xsltdialog/typedetectionexport.cxx
@@ -169,11 +169,11 @@ void TypeDetectionExporter::doExport( Reference< XOutputStream > xOS, const XML
OUString sValue("0");
sValue += sComma;
sValue += pFilter->maType;
- sValue += sComma,
+ sValue += sComma;
sValue += pFilter->maDocumentService;
- sValue += sComma,
+ sValue += sComma;
sValue += sFilterAdaptorService;
- sValue += sComma,
+ sValue += sComma;
sValue += OUString::number( pFilter->maFlags );
sValue += sComma;
sValue += sXSLTFilterService;