sc/inc/conditio.hxx | 2 +- sc/inc/datamapper.hxx | 2 +- sc/inc/document.hxx | 6 +++--- sc/inc/documentimport.hxx | 2 +- sc/source/core/data/documen8.cxx | 2 +- sc/source/core/data/formulacell.cxx | 6 +++--- sc/source/filter/excel/xeroot.cxx | 2 +- sc/source/filter/excel/xestream.cxx | 2 +- sc/source/filter/inc/htmlpars.hxx | 2 +- sc/source/filter/inc/xeroot.hxx | 2 +- sc/source/filter/xml/xmlexprt.cxx | 2 +- sc/source/ui/dataprovider/dataprovider.cxx | 2 +- sc/source/ui/inc/RegressionDialog.hxx | 2 +- 13 files changed, 17 insertions(+), 17 deletions(-)
New commits: commit 5c7dd81ca32bd194b2ab7d181e2e7593d6347730 Author: Noel Grandin <noel.gran...@collabora.co.uk> AuthorDate: Thu Nov 15 15:36:26 2018 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Thu Nov 15 17:34:13 2018 +0100 loplugin:staticmethods in sc Change-Id: I3cdce43e0ba9b17f9bf993ebcad5f64f0834ceaf Reviewed-on: https://gerrit.libreoffice.org/63421 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/sc/inc/conditio.hxx b/sc/inc/conditio.hxx index 65c9067b8700..3b0480e64d6d 100644 --- a/sc/inc/conditio.hxx +++ b/sc/inc/conditio.hxx @@ -323,7 +323,7 @@ class SC_DLLPUBLIC ScConditionEntry : public ScFormatEntry bool bFirstRun; std::unique_ptr<ScFormulaListener> mpListener; - void SimplifyCompiledFormula( std::unique_ptr<ScTokenArray>& rFormula, + static void SimplifyCompiledFormula( std::unique_ptr<ScTokenArray>& rFormula, double& rVal, bool& rIsStr, OUString& rStrVal ); diff --git a/sc/inc/datamapper.hxx b/sc/inc/datamapper.hxx index d54e1a81c2ed..2f8e51d506c0 100644 --- a/sc/inc/datamapper.hxx +++ b/sc/inc/datamapper.hxx @@ -87,7 +87,7 @@ public: const OUString& getProvider() const; const OUString& getID() const; const ScOrcusImportXMLParam& getXMLImportParam() const; - double getUpdateFrequency() const; + static double getUpdateFrequency(); OUString getDBName() const; void setDBData(const OUString& rDBName); ScDBDataManager* getDBManager(); diff --git a/sc/inc/document.hxx b/sc/inc/document.hxx index 603d9590033a..bad7ae69e817 100644 --- a/sc/inc/document.hxx +++ b/sc/inc/document.hxx @@ -284,10 +284,10 @@ struct ScDocumentThreadSpecific } // To be called in the thread at start - void SetupFromNonThreadedData(const ScDocumentThreadSpecific& rNonThreadedData); + static void SetupFromNonThreadedData(const ScDocumentThreadSpecific& rNonThreadedData); // To be called in the main thread after the thread has finished - void MergeBackIntoNonThreadedData(ScDocumentThreadSpecific& rNonThreadedData); + static void MergeBackIntoNonThreadedData(ScDocumentThreadSpecific& rNonThreadedData); }; /// Enumeration to determine which pieces of the code should not be mutated when set. @@ -588,7 +588,7 @@ public: { return IsThreadedGroupCalcInProgress() ? *maThreadSpecific.pContext : GetNonThreadedContext(); } - void SetupFromNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber ); + static void SetupFromNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber ); void MergeBackIntoNonThreadedContext( ScInterpreterContext& threadedContext, int threadNumber ); void SetThreadedGroupCalcInProgress( bool set ) { (void)this; ScGlobal::bThreadedGroupCalcInProgress = set; } bool IsThreadedGroupCalcInProgress() const { (void)this; return ScGlobal::bThreadedGroupCalcInProgress; } diff --git a/sc/inc/documentimport.hxx b/sc/inc/documentimport.hxx index 210ee786a7ea..02e425449176 100644 --- a/sc/inc/documentimport.hxx +++ b/sc/inc/documentimport.hxx @@ -133,7 +133,7 @@ public: private: void initColumn(ScColumn& rCol); - void broadcastRecalcAfterImportColumn(ScColumn& rCol); + static void broadcastRecalcAfterImportColumn(ScColumn& rCol); }; #endif diff --git a/sc/source/core/data/documen8.cxx b/sc/source/core/data/documen8.cxx index 943be7200a68..fb73f88a7bd3 100644 --- a/sc/source/core/data/documen8.cxx +++ b/sc/source/core/data/documen8.cxx @@ -416,7 +416,7 @@ const ScDocumentThreadSpecific& ScDocument::CalculateInColumnInThread( ScInterpr assert(IsThreadedGroupCalcInProgress()); maThreadSpecific.pContext = &rContext; - maThreadSpecific.SetupFromNonThreadedData(maNonThreaded); + ScDocumentThreadSpecific::SetupFromNonThreadedData(maNonThreaded); pTab->CalculateInColumnInThread(rContext, rTopPos.Col(), rTopPos.Row(), nLen, nThisThread, nThreadsTotal); assert(IsThreadedGroupCalcInProgress()); diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx index 187007f83b79..4438e7ef100f 100644 --- a/sc/source/core/data/formulacell.cxx +++ b/sc/source/core/data/formulacell.cxx @@ -4660,8 +4660,8 @@ bool ScFormulaCell::InterpretFormulaGroupThreading(sc::FormulaLogger::GroupScope virtual void doWork() override { - auto aNonThreadedData = mpDocument->CalculateInColumnInThread(*mpContext, mrTopPos, mnLength, mnThisThread, mnThreadsTotal); - aNonThreadedData.MergeBackIntoNonThreadedData(mpDocument->maNonThreaded); + mpDocument->CalculateInColumnInThread(*mpContext, mrTopPos, mnLength, mnThisThread, mnThreadsTotal); + ScDocumentThreadSpecific::MergeBackIntoNonThreadedData(mpDocument->maNonThreaded); } }; @@ -4688,7 +4688,7 @@ bool ScFormulaCell::InterpretFormulaGroupThreading(sc::FormulaLogger::GroupScope for (int i = 0; i < nThreadCount; ++i) { context = aContextGetterGuard.GetInterpreterContextForThreadIdx(i); - pDocument->SetupFromNonThreadedContext(*context, i); + ScDocument::SetupFromNonThreadedContext(*context, i); rThreadPool.pushTask(o3tl::make_unique<Executor>(aTag, i, nThreadCount, pDocument, context, mxGroup->mpTopCell->aPos, mxGroup->mnLength)); } diff --git a/sc/source/filter/excel/xeroot.cxx b/sc/source/filter/excel/xeroot.cxx index 93a0a761106d..086ee95c5bdb 100644 --- a/sc/source/filter/excel/xeroot.cxx +++ b/sc/source/filter/excel/xeroot.cxx @@ -354,7 +354,7 @@ uno::Sequence< beans::NamedValue > XclExpRoot::GetEncryptionData() const return aEncryptionData; } -uno::Sequence< beans::NamedValue > XclExpRoot::GenerateDefaultEncryptionData() const +uno::Sequence< beans::NamedValue > XclExpRoot::GenerateDefaultEncryptionData() { return GenerateEncryptionData( GetDefaultPassword() ); } diff --git a/sc/source/filter/excel/xestream.cxx b/sc/source/filter/excel/xestream.cxx index 46bf1536ebb6..3a3cc34c2bcb 100644 --- a/sc/source/filter/excel/xestream.cxx +++ b/sc/source/filter/excel/xestream.cxx @@ -462,7 +462,7 @@ XclExpBiff8Encrypter::XclExpBiff8Encrypter( const XclExpRoot& rRoot ) : Sequence< NamedValue > aEncryptionData = rRoot.GetEncryptionData(); if( !aEncryptionData.hasElements() ) // Empty password. Get the default biff8 password. - aEncryptionData = rRoot.GenerateDefaultEncryptionData(); + aEncryptionData = XclExpRoot::GenerateDefaultEncryptionData(); Init( aEncryptionData ); } diff --git a/sc/source/filter/inc/htmlpars.hxx b/sc/source/filter/inc/htmlpars.hxx index 52e9c385c77f..d3523e9de602 100644 --- a/sc/source/filter/inc/htmlpars.hxx +++ b/sc/source/filter/inc/htmlpars.hxx @@ -601,7 +601,7 @@ private: /** Closes the current table, regardless on opening tag. */ void CloseTable( const HtmlImportInfo& rInfo ); - void ParseStyle(const OUString& rStrm); + static void ParseStyle(const OUString& rStrm); DECL_LINK( HTMLImportHdl, HtmlImportInfo&, void ); diff --git a/sc/source/filter/inc/xeroot.hxx b/sc/source/filter/inc/xeroot.hxx index 1775c5450591..34d44d752377 100644 --- a/sc/source/filter/inc/xeroot.hxx +++ b/sc/source/filter/inc/xeroot.hxx @@ -177,7 +177,7 @@ public: static css::uno::Sequence< css::beans::NamedValue > GenerateEncryptionData( const OUString& aPass ); css::uno::Sequence< css::beans::NamedValue > GetEncryptionData() const; - css::uno::Sequence< css::beans::NamedValue > GenerateDefaultEncryptionData() const; + static css::uno::Sequence< css::beans::NamedValue > GenerateDefaultEncryptionData(); private: diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index e74be84841f9..6f4109e4f5f7 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -4072,7 +4072,7 @@ void ScXMLExport::WriteExternalDataMapping() { AddAttribute(XML_NAMESPACE_XLINK, XML_HREF, itr.getURL()); AddAttribute(XML_NAMESPACE_CALC_EXT, XML_PROVIDER, itr.getProvider()); - AddAttribute(XML_NAMESPACE_CALC_EXT, XML_DATA_FREQUENCY, OUString::number(itr.getUpdateFrequency())); + AddAttribute(XML_NAMESPACE_CALC_EXT, XML_DATA_FREQUENCY, OUString::number(sc::ExternalDataSource::getUpdateFrequency())); AddAttribute(XML_NAMESPACE_CALC_EXT, XML_ID, itr.getID()); AddAttribute(XML_NAMESPACE_CALC_EXT, XML_DATABASE_NAME, itr.getDBName()); diff --git a/sc/source/ui/dataprovider/dataprovider.cxx b/sc/source/ui/dataprovider/dataprovider.cxx index 6833c68cf03c..f135aed4657a 100644 --- a/sc/source/ui/dataprovider/dataprovider.cxx +++ b/sc/source/ui/dataprovider/dataprovider.cxx @@ -137,7 +137,7 @@ void ExternalDataSource::setDBData(const OUString& rDBName) } } -double ExternalDataSource::getUpdateFrequency() const +double ExternalDataSource::getUpdateFrequency() { return 0; } diff --git a/sc/source/ui/inc/RegressionDialog.hxx b/sc/source/ui/inc/RegressionDialog.hxx index de01004dcc35..7503e07c382d 100644 --- a/sc/source/ui/inc/RegressionDialog.hxx +++ b/sc/source/ui/inc/RegressionDialog.hxx @@ -71,7 +71,7 @@ private: FormulaTemplate& rTemplate, size_t nRegressionIndex); // Generic table writer - void WriteTable(std::function<CellValueGetter>& rCellGetter, size_t nRowsInTable, + static void WriteTable(std::function<CellValueGetter>& rCellGetter, size_t nRowsInTable, size_t nColsInTable, AddressWalkerWriter& rOutput, std::function<CellWriter>& rFunc); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits