summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2021-11-26 12:40:48 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-11-26 17:30:33 +0100
commitbf74eb1d1623a51805f91a973bc9f726d14dd7a8 (patch)
treea61f72760e61e1526c07e27508ecd2d9f2106ad6 /sc/source
parent05766922e7e4262b98e9c3f8d83cdfdaa49d3f7a (diff)
tdf#133996 speed up opening of ODS with autofilter + conditional formatting
inline some hot methods, and use OUStringLiteral to avoid repeated construction of an OUString, saves about 3% Change-Id: I6d09ade4e08a94ed5dd49a8882e26bb5786409d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125873 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/core/data/documen7.cxx10
-rw-r--r--sc/source/core/data/formulacell.cxx3
2 files changed, 2 insertions, 11 deletions
diff --git a/sc/source/core/data/documen7.cxx b/sc/source/core/data/documen7.cxx
index eaaaf285c4b8..dbbbbcae7883 100644
--- a/sc/source/core/data/documen7.cxx
+++ b/sc/source/core/data/documen7.cxx
@@ -318,11 +318,6 @@ void ScDocument::RemoveFromFormulaTree( ScFormulaCell* pCell )
}
}
-bool ScDocument::IsInFormulaTree( const ScFormulaCell* pCell ) const
-{
- return pCell->GetPrevious() || pFormulaTree == pCell;
-}
-
void ScDocument::CalcFormulaTree( bool bOnlyForced, bool bProgressBar, bool bSetAllDirty )
{
OSL_ENSURE( !IsCalculatingFormulaTree(), "CalcFormulaTree recursion" );
@@ -498,11 +493,6 @@ void ScDocument::RemoveFromFormulaTrack( ScFormulaCell* pCell )
--nFormulaTrackCount;
}
-bool ScDocument::IsInFormulaTrack( const ScFormulaCell* pCell ) const
-{
- return pCell->GetPreviousTrack() || pFormulaTrack == pCell;
-}
-
void ScDocument::FinalTrackFormulas( SfxHintId nHintId )
{
mbTrackFormulasPending = false;
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 44f0f7acdf2b..195fa15286d0 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -4614,7 +4614,8 @@ bool ScFormulaCell::InterpretFormulaGroup(SCROW nStartOffset, SCROW nEndOffset)
if (mxGroup->meCalcState == sc::GroupCalcDisabled)
{
- aScope.addMessage("group calc disabled");
+ static constexpr OUStringLiteral MESSAGE = u"group calc disabled";
+ aScope.addMessage(MESSAGE);
return false;
}