diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-08-07 09:42:02 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-08-07 10:28:24 +0200 |
commit | 0582346a1ab5ec8d1b81ea3fef1e40db60c90823 (patch) | |
tree | 71e2cb1f96dceddbbe3457aede6bc28b098ff02b /sw/source/filter/ww8 | |
parent | 57ea9f81ed3553ad71207db9e433774b165732a2 (diff) |
loplugin:constparams in sw part8
Change-Id: I0fb51270da4b8f3049f1af2c2c788e516b3641e8
Reviewed-on: https://gerrit.libreoffice.org/40821
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/filter/ww8')
-rw-r--r-- | sw/source/filter/ww8/WW8Sttbf.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/WW8Sttbf.hxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/WW8TableInfo.cxx | 10 | ||||
-rw-r--r-- | sw/source/filter/ww8/WW8TableInfo.hxx | 8 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxattributeoutput.cxx | 6 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxattributeoutput.hxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxexport.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxexport.hxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/rtfattributeoutput.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/writerhelper.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/writerhelper.hxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/writerwordglue.cxx | 6 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8esh.cxx | 8 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8nds.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtww8.hxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par.hxx | 4 |
16 files changed, 36 insertions, 36 deletions
diff --git a/sw/source/filter/ww8/WW8Sttbf.cxx b/sw/source/filter/ww8/WW8Sttbf.cxx index b97d5e5817b7..5e088e5e0dd4 100644 --- a/sw/source/filter/ww8/WW8Sttbf.cxx +++ b/sw/source/filter/ww8/WW8Sttbf.cxx @@ -42,7 +42,7 @@ namespace ww8 OSL_ENSURE(mn_size == nSize, "short read in WW8Struct::WW8Struct"); } - WW8Struct::WW8Struct(WW8Struct * pStruct, sal_uInt32 nPos, sal_uInt32 nSize) + WW8Struct::WW8Struct(WW8Struct const * pStruct, sal_uInt32 nPos, sal_uInt32 nSize) : m_pData(pStruct->m_pData), mn_offset(pStruct->mn_offset + nPos) , mn_size(nSize) { diff --git a/sw/source/filter/ww8/WW8Sttbf.hxx b/sw/source/filter/ww8/WW8Sttbf.hxx index 179ae6acc1d3..b404d4b69820 100644 --- a/sw/source/filter/ww8/WW8Sttbf.hxx +++ b/sw/source/filter/ww8/WW8Sttbf.hxx @@ -40,7 +40,7 @@ namespace ww8 public: WW8Struct(SvStream& rSt, sal_uInt32 nPos, sal_uInt32 nSize); - WW8Struct(WW8Struct * pStruct, sal_uInt32 nPos, sal_uInt32 nSize); + WW8Struct(WW8Struct const * pStruct, sal_uInt32 nPos, sal_uInt32 nSize); virtual ~WW8Struct() override; sal_uInt8 getU8(sal_uInt32 nOffset); diff --git a/sw/source/filter/ww8/WW8TableInfo.cxx b/sw/source/filter/ww8/WW8TableInfo.cxx index 4439e5ebcb4b..d4d12e86aeef 100644 --- a/sw/source/filter/ww8/WW8TableInfo.cxx +++ b/sw/source/filter/ww8/WW8TableInfo.cxx @@ -734,7 +734,7 @@ WW8TableInfo::processTableBoxLines(const SwTableBox * pBox, return pNodeInfo; } -void updateFinalEndOfLine(RowEndInners_t &rLastRowEnds, WW8TableNodeInfo* pEndOfCellInfo) +void updateFinalEndOfLine(RowEndInners_t &rLastRowEnds, WW8TableNodeInfo const * pEndOfCellInfo) { sal_Int32 nDepth = pEndOfCellInfo->getDepth(); WW8TableNodeInfoInner::Pointer_t pInner = pEndOfCellInfo->getInnerForDepth(nDepth); @@ -849,7 +849,7 @@ WW8TableNodeInfo::Pointer_t WW8TableInfo::insertTableNodeInfo sal_uInt32 nRow, sal_uInt32 nCell, sal_uInt32 nDepth, - SwRect * pRect) + SwRect const * pRect) { WW8TableNodeInfo::Pointer_t pNodeInfo = getTableNodeInfo(pNode); @@ -1365,7 +1365,7 @@ std::string WW8TableCellGrid::toString() #endif TableBoxVectorPtr WW8TableCellGrid::getTableBoxesOfRow -(WW8TableNodeInfoInner * pNodeInfoInner) +(WW8TableNodeInfoInner const * pNodeInfoInner) { TableBoxVectorPtr pResult; WW8TableCellGridRow::Pointer_t pRow = @@ -1380,7 +1380,7 @@ TableBoxVectorPtr WW8TableCellGrid::getTableBoxesOfRow } WidthsPtr WW8TableCellGrid::getWidthsOfRow -(WW8TableNodeInfoInner * pNodeInfoInner) +(WW8TableNodeInfoInner const * pNodeInfoInner) { GridColsPtr pResult; @@ -1396,7 +1396,7 @@ WidthsPtr WW8TableCellGrid::getWidthsOfRow } RowSpansPtr WW8TableCellGrid::getRowSpansOfRow -(WW8TableNodeInfoInner * pNodeInfoInner) +(WW8TableNodeInfoInner const * pNodeInfoInner) { RowSpansPtr pResult; diff --git a/sw/source/filter/ww8/WW8TableInfo.hxx b/sw/source/filter/ww8/WW8TableInfo.hxx index 6d2b814f1882..a3b6df799180 100644 --- a/sw/source/filter/ww8/WW8TableInfo.hxx +++ b/sw/source/filter/ww8/WW8TableInfo.hxx @@ -282,9 +282,9 @@ public: std::string toString(); #endif - TableBoxVectorPtr getTableBoxesOfRow(WW8TableNodeInfoInner * pNodeInfo); - WidthsPtr getWidthsOfRow(WW8TableNodeInfoInner * pNodeInfo); - RowSpansPtr getRowSpansOfRow(WW8TableNodeInfoInner * pNodeInfo); + TableBoxVectorPtr getTableBoxesOfRow(WW8TableNodeInfoInner const * pNodeInfo); + WidthsPtr getWidthsOfRow(WW8TableNodeInfoInner const * pNodeInfo); + RowSpansPtr getRowSpansOfRow(WW8TableNodeInfoInner const * pNodeInfo); }; class WW8TableInfo final @@ -328,7 +328,7 @@ class WW8TableInfo final sal_uInt32 nRow, sal_uInt32 nCell, sal_uInt32 nDepth, - SwRect * pRect = nullptr); + SwRect const * pRect = nullptr); WW8TableCellGrid::Pointer_t getCellGridForTable(const SwTable * pTable, bool bCreate = true); diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx index 7f6f312e5d8b..e09bdaae67b9 100644 --- a/sw/source/filter/ww8/docxattributeoutput.cxx +++ b/sw/source/filter/ww8/docxattributeoutput.cxx @@ -1502,7 +1502,7 @@ void DocxAttributeOutput::WriteFFData( const FieldInfos& rInfos ) } } -void DocxAttributeOutput::StartField_Impl( FieldInfos& rInfos, bool bWriteRun ) +void DocxAttributeOutput::StartField_Impl( FieldInfos const & rInfos, bool bWriteRun ) { if ( rInfos.pField && rInfos.eType == ww::eUNKNOWN ) { @@ -1587,7 +1587,7 @@ void DocxAttributeOutput::DoWriteCmd( const OUString& rCmd ) } -void DocxAttributeOutput::CmdField_Impl( FieldInfos& rInfos ) +void DocxAttributeOutput::CmdField_Impl( FieldInfos const & rInfos ) { m_pSerializer->startElementNS( XML_w, XML_r, FSEND ); sal_Int32 nNbToken = comphelper::string::getTokenCount(rInfos.sCmd, '\t'); @@ -2774,7 +2774,7 @@ static bool boxHasLineLargerThan31(const SvxBoxItem& rBox) ); } -static void impl_borders( FSHelperPtr const & pSerializer, const SvxBoxItem& rBox, const OutputBorderOptions& rOptions, PageMargins* pageMargins, +static void impl_borders( FSHelperPtr const & pSerializer, const SvxBoxItem& rBox, const OutputBorderOptions& rOptions, PageMargins const * pageMargins, std::map<SvxBoxItemLine, css::table::BorderLine2> &rTableStyleConf ) { static const SvxBoxItemLine aBorders[] = diff --git a/sw/source/filter/ww8/docxattributeoutput.hxx b/sw/source/filter/ww8/docxattributeoutput.hxx index 712ae06b9589..49efe1d6c72d 100644 --- a/sw/source/filter/ww8/docxattributeoutput.hxx +++ b/sw/source/filter/ww8/docxattributeoutput.hxx @@ -713,9 +713,9 @@ private: /// Closes a currently open SDT block. void EndSdtBlock(); - void StartField_Impl( FieldInfos& rInfos, bool bWriteRun = false ); + void StartField_Impl( FieldInfos const & rInfos, bool bWriteRun = false ); void DoWriteCmd( const OUString& rCmd ); - void CmdField_Impl( FieldInfos& rInfos ); + void CmdField_Impl( FieldInfos const & rInfos ); void EndField_Impl( FieldInfos& rInfos ); static void AddToAttrList( rtl::Reference<sax_fastparser::FastAttributeList>& pAttrList, sal_Int32 nAttrName, const sal_Char* sAttrValue ); diff --git a/sw/source/filter/ww8/docxexport.cxx b/sw/source/filter/ww8/docxexport.cxx index 6ff65f09db50..b5c5e0bba337 100644 --- a/sw/source/filter/ww8/docxexport.cxx +++ b/sw/source/filter/ww8/docxexport.cxx @@ -355,7 +355,7 @@ void DocxExport::DoFormText(const SwInputField* /*pField*/) SAL_INFO("sw.ww8", "TODO DocxExport::ForFormText()" ); } -OString DocxExport::OutputChart( uno::Reference< frame::XModel >& xModel, sal_Int32 nCount, ::sax_fastparser::FSHelperPtr const & m_pSerializer ) +OString DocxExport::OutputChart( uno::Reference< frame::XModel > const & xModel, sal_Int32 nCount, ::sax_fastparser::FSHelperPtr const & m_pSerializer ) { OUString aFileName = "charts/chart" + OUString::number(nCount) + ".xml"; OUString sId = m_pFilter->addRelation( m_pSerializer->getOutputStream(), @@ -419,7 +419,7 @@ OString DocxExport::WriteOLEObject(SwOLEObj& rObject, OUString & io_rProgID) return OUStringToOString( sId, RTL_TEXTENCODING_UTF8 ); } -void DocxExport::OutputDML(uno::Reference<drawing::XShape>& xShape) +void DocxExport::OutputDML(uno::Reference<drawing::XShape> const & xShape) { uno::Reference<lang::XServiceInfo> xServiceInfo(xShape, uno::UNO_QUERY_THROW); sal_Int32 nNamespace = XML_wps; diff --git a/sw/source/filter/ww8/docxexport.hxx b/sw/source/filter/ww8/docxexport.hxx index b3627639eb96..915f50122bfc 100644 --- a/sw/source/filter/ww8/docxexport.hxx +++ b/sw/source/filter/ww8/docxexport.hxx @@ -172,11 +172,11 @@ public: virtual sal_uLong ReplaceCr( sal_uInt8 nChar ) override; /// Returns the relationd id - OString OutputChart( css::uno::Reference< css::frame::XModel >& xModel, sal_Int32 nCount, ::sax_fastparser::FSHelperPtr const & m_pSerializer ); + OString OutputChart( css::uno::Reference< css::frame::XModel > const & xModel, sal_Int32 nCount, ::sax_fastparser::FSHelperPtr const & m_pSerializer ); OString WriteOLEObject(SwOLEObj& rObject, OUString & io_rProgID); /// Writes the shape using drawingML syntax. - void OutputDML( css::uno::Reference< css::drawing::XShape >& xShape ); + void OutputDML( css::uno::Reference< css::drawing::XShape > const & xShape ); void WriteOutliner(const OutlinerParaObject& rOutliner, sal_uInt8 nTyp); diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx index bda4776a8572..23885ec5e83e 100644 --- a/sw/source/filter/ww8/rtfattributeoutput.cxx +++ b/sw/source/filter/ww8/rtfattributeoutput.cxx @@ -85,7 +85,7 @@ using namespace ::com::sun::star; using namespace sw::util; -static OString OutTBLBorderLine(RtfExport& rExport, const editeng::SvxBorderLine* pLine, const sal_Char* pStr) +static OString OutTBLBorderLine(RtfExport const & rExport, const editeng::SvxBorderLine* pLine, const sal_Char* pStr) { OStringBuffer aRet; if (!pLine->isEmpty()) @@ -165,7 +165,7 @@ static OString OutTBLBorderLine(RtfExport& rExport, const editeng::SvxBorderLine return aRet.makeStringAndClear(); } -static OString OutBorderLine(RtfExport& rExport, const editeng::SvxBorderLine* pLine, +static OString OutBorderLine(RtfExport const & rExport, const editeng::SvxBorderLine* pLine, const sal_Char* pStr, sal_uInt16 nDist, SvxShadowLocation eShadowLocation = SvxShadowLocation::NONE) { OStringBuffer aRet; diff --git a/sw/source/filter/ww8/writerhelper.cxx b/sw/source/filter/ww8/writerhelper.cxx index e184f089c5e4..cd4a10e121c8 100644 --- a/sw/source/filter/ww8/writerhelper.cxx +++ b/sw/source/filter/ww8/writerhelper.cxx @@ -508,7 +508,7 @@ namespace sw Utility to extract FlyFormats from a document, potentially from a selection. */ - ww8::Frames GetFrames(const SwDoc &rDoc, SwPaM *pPaM /*, bool bAll*/) + ww8::Frames GetFrames(const SwDoc &rDoc, SwPaM const *pPaM /*, bool bAll*/) { SwPosFlyFrames aFlys(rDoc.GetAllFlyFormats(pPaM, true)); ww8::Frames aRet(SwPosFlyFramesToFrames(aFlys)); diff --git a/sw/source/filter/ww8/writerhelper.hxx b/sw/source/filter/ww8/writerhelper.hxx index 380a957ccb70..cf6e379df9ec 100644 --- a/sw/source/filter/ww8/writerhelper.hxx +++ b/sw/source/filter/ww8/writerhelper.hxx @@ -517,7 +517,7 @@ namespace sw @return A Frames containing the selections Floating elements */ - ww8::Frames GetFrames(const SwDoc &rDoc, SwPaM *pPaM); + ww8::Frames GetFrames(const SwDoc &rDoc, SwPaM const *pPaM); /** fix up frame positions, must be called after SetRedlineFlags */ void UpdateFramePositions(ww8::Frames & rFrames); diff --git a/sw/source/filter/ww8/writerwordglue.cxx b/sw/source/filter/ww8/writerwordglue.cxx index dcc9aaaabe75..06f9b870977a 100644 --- a/sw/source/filter/ww8/writerwordglue.cxx +++ b/sw/source/filter/ww8/writerwordglue.cxx @@ -1047,15 +1047,15 @@ namespace sw return nKey; } - bool IsPreviousAM(OUString& rParams, sal_Int32 nPos) + bool IsPreviousAM(OUString const & rParams, sal_Int32 nPos) { return nPos>=2 && rParams.matchIgnoreAsciiCase("am", nPos-2); } - bool IsNextPM(OUString& rParams, sal_Int32 nPos) + bool IsNextPM(OUString const & rParams, sal_Int32 nPos) { return nPos+2<rParams.getLength() && rParams.matchIgnoreAsciiCase("pm", nPos+1); } - bool IsNotAM(OUString& rParams, sal_Int32 nPos) + bool IsNotAM(OUString const & rParams, sal_Int32 nPos) { ++nPos; return nPos>=rParams.getLength() || (rParams[nPos]!='M' && rParams[nPos]!='m'); diff --git a/sw/source/filter/ww8/wrtw8esh.cxx b/sw/source/filter/ww8/wrtw8esh.cxx index ce1e3df8572c..e15b6854f1ee 100644 --- a/sw/source/filter/ww8/wrtw8esh.cxx +++ b/sw/source/filter/ww8/wrtw8esh.cxx @@ -318,7 +318,7 @@ namespace /// @param rWrt The containing WW8Export. /// @param pObj pointer to the drawing object. /// @returns The ordering number. - sal_uLong lcl_getSdrOrderNumber(const WW8Export& rWrt, DrawObj *pObj) + sal_uLong lcl_getSdrOrderNumber(const WW8Export& rWrt, DrawObj const *pObj) { return rWrt.GetSdrOrdNum(pObj->maContent.GetFrameFormat()); }; @@ -936,7 +936,7 @@ DrawObj& DrawObj::operator=(const DrawObj& rOther) return *this; } -bool PlcDrawObj::Append( WW8Export& rWrt, WW8_CP nCp, const ww8::Frame& rFormat, +bool PlcDrawObj::Append( WW8Export const & rWrt, WW8_CP nCp, const ww8::Frame& rFormat, const Point& rNdTopLeft ) { bool bRet = false; @@ -3109,7 +3109,7 @@ sal_uInt32 SwEscherEx::QueryTextID( return nId; } -SwMSConvertControls::SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ) : oox +SwMSConvertControls::SwMSConvertControls( SfxObjectShell const *pDSh, SwPaM *pP ) : oox ::ole::MSConvertOCXControls( pDSh ? pDSh->GetModel() : nullptr ), pPaM( pP ), mnObjectId(0) { } @@ -3117,7 +3117,7 @@ SwMSConvertControls::SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ) : oox // in transitioning away old filter for ole/ocx controls, ReadOCXStream has been made pure virtual in // filter/source/msocximex.cxx, so.. we need an implementation here -bool SwMSConvertControls::ReadOCXStream( tools::SvRef<SotStorage>& rSrc1, +bool SwMSConvertControls::ReadOCXStream( tools::SvRef<SotStorage> const & rSrc1, css::uno::Reference< css::drawing::XShape > *pShapeRef, bool bFloatingCtrl ) { diff --git a/sw/source/filter/ww8/wrtw8nds.cxx b/sw/source/filter/ww8/wrtw8nds.cxx index 5218eaacc26c..cb8807c5ecfa 100644 --- a/sw/source/filter/ww8/wrtw8nds.cxx +++ b/sw/source/filter/ww8/wrtw8nds.cxx @@ -1776,7 +1776,7 @@ void WW8AttributeOutput::FormatDrop( const SwTextNode& rNode, const SwFormatDrop m_rWW8Export.pO->clear(); } -sal_Int32 MSWordExportBase::GetNextPos( SwWW8AttrIter* aAttrIter, const SwTextNode& rNode, sal_Int32 nAktPos ) +sal_Int32 MSWordExportBase::GetNextPos( SwWW8AttrIter const * aAttrIter, const SwTextNode& rNode, sal_Int32 nAktPos ) { // Get the bookmarks for the normal run const sal_Int32 nNextPos = aAttrIter->WhereNext(); diff --git a/sw/source/filter/ww8/wrtww8.hxx b/sw/source/filter/ww8/wrtww8.hxx index bb371dcdc5b7..83aa12ecb3c8 100644 --- a/sw/source/filter/ww8/wrtww8.hxx +++ b/sw/source/filter/ww8/wrtww8.hxx @@ -370,7 +370,7 @@ protected: public: PlcDrawObj() {} void WritePlc( WW8Export& rWrt ) const; - bool Append( WW8Export&, WW8_CP nCp, const ww8::Frame& rFormat, + bool Append( WW8Export const &, WW8_CP nCp, const ww8::Frame& rFormat, const Point& rNdTopLeft ); int size() { return maDrawObjs.size(); }; DrawObjVector &GetObjArr() { return maDrawObjs; } @@ -788,7 +788,7 @@ protected: virtual void ExportDocument_Impl() = 0; /// Get the next position in the text node to output - sal_Int32 GetNextPos( SwWW8AttrIter* pAttrIter, const SwTextNode& rNode, sal_Int32 nAktPos ); + sal_Int32 GetNextPos( SwWW8AttrIter const * pAttrIter, const SwTextNode& rNode, sal_Int32 nAktPos ); /// Update the information for GetNextPos(). void UpdatePosition( SwWW8AttrIter* pAttrIter, sal_Int32 nAktPos ); diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx index 6ad6db3cd749..c038ded95f8c 100644 --- a/sw/source/filter/ww8/ww8par.hxx +++ b/sw/source/filter/ww8/ww8par.hxx @@ -719,13 +719,13 @@ public: class SwMSConvertControls: public oox::ole::MSConvertOCXControls { public: - SwMSConvertControls( SfxObjectShell *pDSh,SwPaM *pP ); + SwMSConvertControls( SfxObjectShell const *pDSh, SwPaM *pP ); void InsertFormula( WW8FormulaControl &rFormula); virtual bool InsertControl(const css::uno::Reference< css::form::XFormComponent >& rFComp, const css::awt::Size& rSize, css::uno::Reference< css::drawing::XShape > *pShape, bool bFloatingCtrl) override; void ExportControl(WW8Export &rWrt, const SdrUnoObj& rFormObj); - bool ReadOCXStream( tools::SvRef<SotStorage>& rSrc1, + bool ReadOCXStream( tools::SvRef<SotStorage> const & rSrc1, css::uno::Reference< css::drawing::XShape > *pShapeRef, bool bFloatingCtrl=false ); private: |