summaryrefslogtreecommitdiff
path: root/sc/source/core/data/documen2.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/core/data/documen2.cxx')
-rw-r--r--sc/source/core/data/documen2.cxx47
1 files changed, 0 insertions, 47 deletions
diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx
index 2188a458a855..756990e681bc 100644
--- a/sc/source/core/data/documen2.cxx
+++ b/sc/source/core/data/documen2.cxx
@@ -1130,53 +1130,6 @@ void ScDocument::SetError( SCCOL nCol, SCROW nRow, SCTAB nTab, const sal_uInt16
pTab[nTab]->SetError( nCol, nRow, nError );
}
-namespace {
-
-bool eraseUnusedSharedName(ScRangeName* pRangeName, ScTable* pTab[], sal_uInt16 nLevel)
-{
- if (!pRangeName)
- return false;
-
- ScRangeName::iterator itr = pRangeName->begin(), itrEnd = pRangeName->end();
- for (; itr != itrEnd; ++itr)
- {
- if (!itr->HasType(RT_SHARED))
- continue;
-
- String aName;
- itr->GetName(aName);
- aName.Erase(0, 6); // !!! vgl. Table4, FillFormula !!
- sal_uInt16 nInd = static_cast<sal_uInt16>(aName.ToInt32());
- if (nInd > nLevel)
- continue;
-
- sal_uInt16 nIndex = itr->GetIndex();
-
- bool bInUse = false;
- for (SCTAB j = 0; !bInUse && (j <= MAXTAB); ++j)
- {
- if (pTab[j])
- bInUse = pTab[j]->IsRangeNameInUse(0, 0, MAXCOL-1, MAXROW-1, nIndex);
- }
- if (!bInUse)
- {
- pRangeName->erase(itr);
- return true;
- }
- }
- return false;
-}
-
-}
-
-void ScDocument::EraseNonUsedSharedNames(sal_uInt16 nLevel)
-{
- if (!pRangeName)
- return;
- while (eraseUnusedSharedName(pRangeName, pTab, nLevel))
- ;
-}
-
// ----------------------------------------------------------------------------
void ScDocument::SetConsolidateDlgData( const ScConsolidateParam* pData )