diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-08-24 12:24:44 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-08-24 15:15:14 +0200 |
commit | c137c2a46cd2276938d572c97fb111b9aa31cdfd (patch) | |
tree | 9fe4c1809e836f3c177fd930b632af6cad5407c0 /sc/source/ui/docshell | |
parent | 9fe857b7bd126ff4856fc4689d375881653b97a2 (diff) |
loplugin:constparam in sc part5
Change-Id: Iba249d4d8f7cc686941106983031bae53c7528e1
Reviewed-on: https://gerrit.libreoffice.org/41510
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/docshell')
-rw-r--r-- | sc/source/ui/docshell/arealink.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/docshell/dbdocfun.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/docshell/dbdocimp.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/docshell/docfunc.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/docshell/docsh.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/docshell/docsh4.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/docshell/editable.cxx | 16 | ||||
-rw-r--r-- | sc/source/ui/docshell/externalrefmgr.cxx | 14 | ||||
-rw-r--r-- | sc/source/ui/docshell/impex.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/docshell/tablink.cxx | 2 |
10 files changed, 25 insertions, 25 deletions
diff --git a/sc/source/ui/docshell/arealink.cxx b/sc/source/ui/docshell/arealink.cxx index 425af099b597..4e4c8ab847af 100644 --- a/sc/source/ui/docshell/arealink.cxx +++ b/sc/source/ui/docshell/arealink.cxx @@ -194,7 +194,7 @@ bool ScAreaLink::IsEqual( const OUString& rFile, const OUString& rFilter, const } // find a range with name >rAreaName< in >pSrcDoc<, return it in >rRange< -bool ScAreaLink::FindExtRange( ScRange& rRange, ScDocument* pSrcDoc, const OUString& rAreaName ) +bool ScAreaLink::FindExtRange( ScRange& rRange, const ScDocument* pSrcDoc, const OUString& rAreaName ) { bool bFound = false; OUString aUpperName = ScGlobal::pCharClass->uppercase(rAreaName); diff --git a/sc/source/ui/docshell/dbdocfun.cxx b/sc/source/ui/docshell/dbdocfun.cxx index 11c53f1c8278..df07acaebfc3 100644 --- a/sc/source/ui/docshell/dbdocfun.cxx +++ b/sc/source/ui/docshell/dbdocfun.cxx @@ -1580,7 +1580,7 @@ bool ScDBDocFunc::UpdatePivotTable(ScDPObject& rDPObj, bool bRecord, bool bApi) return true; } -void ScDBDocFunc::RefreshPivotTables(ScDPObject* pDPObj, bool bApi) +void ScDBDocFunc::RefreshPivotTables(const ScDPObject* pDPObj, bool bApi) { ScDPCollection* pDPs = rDocShell.GetDocument().GetDPCollection(); if (!pDPs) diff --git a/sc/source/ui/docshell/dbdocimp.cxx b/sc/source/ui/docshell/dbdocimp.cxx index 60c379ed0174..8979252bb5d3 100644 --- a/sc/source/ui/docshell/dbdocimp.cxx +++ b/sc/source/ui/docshell/dbdocimp.cxx @@ -64,7 +64,7 @@ using namespace com::sun::star; #define SC_DBPROP_COMMAND "Command" #define SC_DBPROP_COMMANDTYPE "CommandType" -void ScDBDocFunc::ShowInBeamer( const ScImportParam& rParam, SfxViewFrame* pFrame ) +void ScDBDocFunc::ShowInBeamer( const ScImportParam& rParam, const SfxViewFrame* pFrame ) { // called after opening the database beamer diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx index c9e19236a699..6cc3ae4db697 100644 --- a/sc/source/ui/docshell/docfunc.cxx +++ b/sc/source/ui/docshell/docfunc.cxx @@ -2997,7 +2997,7 @@ bool ScDocFunc::MoveBlock( const ScRange& rSource, const ScAddress& rDestPos, return true; } -uno::Reference< uno::XInterface > GetDocModuleObject( SfxObjectShell& rDocSh, OUString& sCodeName ) +uno::Reference< uno::XInterface > GetDocModuleObject( const SfxObjectShell& rDocSh, const OUString& sCodeName ) { uno::Reference< lang::XMultiServiceFactory> xSF(rDocSh.GetModel(), uno::UNO_QUERY); uno::Reference< container::XNameAccess > xVBACodeNamedObjectAccess; @@ -3011,7 +3011,7 @@ uno::Reference< uno::XInterface > GetDocModuleObject( SfxObjectShell& rDocSh, OU } -static script::ModuleInfo lcl_InitModuleInfo( SfxObjectShell& rDocSh, OUString& sModule ) +static script::ModuleInfo lcl_InitModuleInfo( const SfxObjectShell& rDocSh, const OUString& sModule ) { script::ModuleInfo sModuleInfo; sModuleInfo.ModuleType = script::ModuleType::DOCUMENT; diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 2e26e5d2386e..3c9d8c5d3c73 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -2951,7 +2951,7 @@ ScFormatSaveData* ScDocShell::GetFormatSaveData() namespace { -void removeKeysIfExists(Reference<ui::XAcceleratorConfiguration>& xScAccel, const vector<const awt::KeyEvent*>& rKeys) +void removeKeysIfExists(const Reference<ui::XAcceleratorConfiguration>& xScAccel, const vector<const awt::KeyEvent*>& rKeys) { vector<const awt::KeyEvent*>::const_iterator itr = rKeys.begin(), itrEnd = rKeys.end(); for (; itr != itrEnd; ++itr) diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx index 341cd921a87f..a0c76fced7b1 100644 --- a/sc/source/ui/docshell/docsh4.cxx +++ b/sc/source/ui/docshell/docsh4.cxx @@ -1534,7 +1534,7 @@ void ScDocShell::PageStyleModified( const OUString& rStyleName, bool bApi ) } } -void ScDocShell::ExecutePageStyle( SfxViewShell& rCaller, +void ScDocShell::ExecutePageStyle( const SfxViewShell& rCaller, SfxRequest& rReq, SCTAB nCurTab ) { diff --git a/sc/source/ui/docshell/editable.cxx b/sc/source/ui/docshell/editable.cxx index feb34d0b41bf..22e1ed7027ff 100644 --- a/sc/source/ui/docshell/editable.cxx +++ b/sc/source/ui/docshell/editable.cxx @@ -29,7 +29,7 @@ ScEditableTester::ScEditableTester() : { } -ScEditableTester::ScEditableTester( ScDocument* pDoc, SCTAB nTab, +ScEditableTester::ScEditableTester( const ScDocument* pDoc, SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow ) : mbIsEditable(true), mbOnlyMatrix(true) @@ -37,7 +37,7 @@ ScEditableTester::ScEditableTester( ScDocument* pDoc, SCTAB nTab, TestBlock( pDoc, nTab, nStartCol, nStartRow, nEndCol, nEndRow ); } -ScEditableTester::ScEditableTester( ScDocument* pDoc, +ScEditableTester::ScEditableTester( const ScDocument* pDoc, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData& rMark ) : mbIsEditable(true), @@ -46,14 +46,14 @@ ScEditableTester::ScEditableTester( ScDocument* pDoc, TestSelectedBlock( pDoc, nStartCol, nStartRow, nEndCol, nEndRow, rMark ); } -ScEditableTester::ScEditableTester( ScDocument* pDoc, const ScRange& rRange ) : +ScEditableTester::ScEditableTester( const ScDocument* pDoc, const ScRange& rRange ) : mbIsEditable(true), mbOnlyMatrix(true) { TestRange( pDoc, rRange ); } -ScEditableTester::ScEditableTester( ScDocument* pDoc, const ScMarkData& rMark ) : +ScEditableTester::ScEditableTester( const ScDocument* pDoc, const ScMarkData& rMark ) : mbIsEditable(true), mbOnlyMatrix(true) { @@ -80,7 +80,7 @@ ScEditableTester::ScEditableTester( TestBlockForAction(rDoc, eAction, nStart, nEnd, rMark); } -void ScEditableTester::TestBlock( ScDocument* pDoc, SCTAB nTab, +void ScEditableTester::TestBlock( const ScDocument* pDoc, SCTAB nTab, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow ) { if (mbIsEditable || mbOnlyMatrix) @@ -95,7 +95,7 @@ void ScEditableTester::TestBlock( ScDocument* pDoc, SCTAB nTab, } } -void ScEditableTester::TestSelectedBlock( ScDocument* pDoc, +void ScEditableTester::TestSelectedBlock( const ScDocument* pDoc, SCCOL nStartCol, SCROW nStartRow, SCCOL nEndCol, SCROW nEndRow, const ScMarkData& rMark ) { @@ -105,7 +105,7 @@ void ScEditableTester::TestSelectedBlock( ScDocument* pDoc, TestBlock( pDoc, *itr, nStartCol, nStartRow, nEndCol, nEndRow ); } -void ScEditableTester::TestRange( ScDocument* pDoc, const ScRange& rRange ) +void ScEditableTester::TestRange( const ScDocument* pDoc, const ScRange& rRange ) { SCCOL nStartCol = rRange.aStart.Col(); SCROW nStartRow = rRange.aStart.Row(); @@ -117,7 +117,7 @@ void ScEditableTester::TestRange( ScDocument* pDoc, const ScRange& rRange ) TestBlock( pDoc, nTab, nStartCol, nStartRow, nEndCol, nEndRow ); } -void ScEditableTester::TestSelection( ScDocument* pDoc, const ScMarkData& rMark ) +void ScEditableTester::TestSelection( const ScDocument* pDoc, const ScMarkData& rMark ) { if (mbIsEditable || mbOnlyMatrix) { diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx index cc2018961f66..9c82c94dcdd0 100644 --- a/sc/source/ui/docshell/externalrefmgr.cxx +++ b/sc/source/ui/docshell/externalrefmgr.cxx @@ -1511,7 +1511,7 @@ void ScExternalRefLink::SetDoReferesh(bool b) mbDoRefresh = b; } -static FormulaToken* convertToToken( ScDocument* pHostDoc, ScDocument* pSrcDoc, ScRefCellValue& rCell ) +static FormulaToken* convertToToken( ScDocument* pHostDoc, const ScDocument* pSrcDoc, ScRefCellValue& rCell ) { if (rCell.hasEmptyValue()) { @@ -1555,7 +1555,7 @@ static FormulaToken* convertToToken( ScDocument* pHostDoc, ScDocument* pSrcDoc, } static std::unique_ptr<ScTokenArray> convertToTokenArray( - ScDocument* pHostDoc, ScDocument* pSrcDoc, ScRange& rRange, vector<ScExternalRefCache::SingleRangeData>& rCacheData ) + ScDocument* pHostDoc, const ScDocument* pSrcDoc, ScRange& rRange, vector<ScExternalRefCache::SingleRangeData>& rCacheData ) { ScAddress& s = rRange.aStart; ScAddress& e = rRange.aEnd; @@ -1701,7 +1701,7 @@ ScExternalRefManager::LinkListener::~LinkListener() { } -ScExternalRefManager::ApiGuard::ApiGuard(ScDocument* pDoc) : +ScExternalRefManager::ApiGuard::ApiGuard(const ScDocument* pDoc) : mpMgr(pDoc->GetExternalRefManager()), mbOldInteractionEnabled(mpMgr->mbUserInteractionEnabled) { @@ -2080,7 +2080,7 @@ ScExternalRefCache::TokenArrayRef ScExternalRefManager::getRangeNameTokens( namespace { -bool hasRangeName(ScDocument& rDoc, const OUString& rName) +bool hasRangeName(const ScDocument& rDoc, const OUString& rName) { ScRangeName* pExtNames = rDoc.GetRangeName(); OUString aUpperName = ScGlobal::pCharClass->uppercase(rName); @@ -2149,7 +2149,7 @@ void ScExternalRefManager::refreshAllRefCells(sal_uInt16 nFileId) namespace { void insertRefCellByIterator( - ScExternalRefManager::RefCellMap::iterator& itr, ScFormulaCell* pCell) + const ScExternalRefManager::RefCellMap::iterator& itr, ScFormulaCell* pCell) { if (pCell) { @@ -2262,7 +2262,7 @@ ScExternalRefCache::TokenRef ScExternalRefManager::getSingleRefTokenFromSrcDoc( } ScExternalRefCache::TokenArrayRef ScExternalRefManager::getDoubleRefTokensFromSrcDoc( - ScDocument* pSrcDoc, const OUString& rTabName, ScRange& rRange, + const ScDocument* pSrcDoc, const OUString& rTabName, ScRange& rRange, vector<ScExternalRefCache::SingleRangeData>& rCacheData) { ScExternalRefCache::TokenArrayRef pArray; @@ -2306,7 +2306,7 @@ ScExternalRefCache::TokenArrayRef ScExternalRefManager::getDoubleRefTokensFromSr } ScExternalRefCache::TokenArrayRef ScExternalRefManager::getRangeNameTokensFromSrcDoc( - sal_uInt16 nFileId, ScDocument* pSrcDoc, OUString& rName) + sal_uInt16 nFileId, const ScDocument* pSrcDoc, OUString& rName) { ScRangeName* pExtNames = pSrcDoc->GetRangeName(); OUString aUpperName = ScGlobal::pCharClass->uppercase(rName); diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx index f992c18061c0..a202ce30b36a 100644 --- a/sc/source/ui/docshell/impex.cxx +++ b/sc/source/ui/docshell/impex.cxx @@ -929,8 +929,8 @@ static bool lcl_PutString( ScDocumentImport& rDocImport, bool bUseDocImport, SCCOL nCol, SCROW nRow, SCTAB nTab, const OUString& rStr, sal_uInt8 nColFormat, SvNumberFormatter* pFormatter, bool bDetectNumFormat, - ::utl::TransliterationWrapper& rTransliteration, CalendarWrapper& rCalendar, - ::utl::TransliterationWrapper* pSecondTransliteration, CalendarWrapper* pSecondCalendar ) + const ::utl::TransliterationWrapper& rTransliteration, CalendarWrapper& rCalendar, + const ::utl::TransliterationWrapper* pSecondTransliteration, CalendarWrapper* pSecondCalendar ) { ScDocument* pDoc = &rDocImport.getDoc(); bool bMultiLine = false; diff --git a/sc/source/ui/docshell/tablink.cxx b/sc/source/ui/docshell/tablink.cxx index 5c5e3a1f4d32..19b1f68d62f2 100644 --- a/sc/source/ui/docshell/tablink.cxx +++ b/sc/source/ui/docshell/tablink.cxx @@ -416,7 +416,7 @@ IMPL_LINK( ScTableLink, TableEndEditHdl, ::sfx2::SvBaseLink&, rLink, void ) // === ScDocumentLoader ================================================== -OUString ScDocumentLoader::GetOptions( SfxMedium& rMedium ) +OUString ScDocumentLoader::GetOptions( const SfxMedium& rMedium ) { SfxItemSet* pSet = rMedium.GetItemSet(); const SfxPoolItem* pItem; |