summaryrefslogtreecommitdiff
path: root/sw/source/core/SwNumberTree
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/SwNumberTree')
-rw-r--r--sw/source/core/SwNumberTree/SwNodeNum.cxx101
-rw-r--r--sw/source/core/SwNumberTree/SwNumberTree.cxx44
2 files changed, 0 insertions, 145 deletions
diff --git a/sw/source/core/SwNumberTree/SwNodeNum.cxx b/sw/source/core/SwNumberTree/SwNodeNum.cxx
index 39e73f025d4d..e60000c24b22 100644
--- a/sw/source/core/SwNumberTree/SwNodeNum.cxx
+++ b/sw/source/core/SwNumberTree/SwNodeNum.cxx
@@ -199,13 +199,6 @@ bool SwNodeNum::IsCounted() const
{
// --> OD 2006-01-25 #i59559#
// <SwTxtNode::IsCounted()> determines, if a text node is counted for numbering
-// const SwNumFmt * pNumFmt = GetNumFmt();
-// if (pNumFmt)
-// {
-// sal_Int16 nType = pNumFmt->GetNumberingType();
-// if ( nType != SVX_NUM_NUMBER_NONE)
-// aResult = mpTxtNode->IsCounted();
-// }
aResult = GetTxtNode()->IsCountedInList();
// <--
}
@@ -273,9 +266,6 @@ bool SwNodeNum::LessThan(const SwNumberTreeNode & rNode) const
{
// --> OD 2007-10-31 #i83479# - refactoring
// simplify comparison by comparing the indexes of the text nodes
-// SwPosition aMyPos(*mpTxtNode);
-// SwPosition aHisPos(*rTmpNode.mpTxtNode);
-// bResult = (aMyPos < aHisPos) ? true : false;
bResult = ( mpTxtNode->GetIndex() < rTmpNode.mpTxtNode->GetIndex() ) ? true : false;
// <--
}
@@ -283,23 +273,6 @@ bool SwNodeNum::LessThan(const SwNumberTreeNode & rNode) const
return bResult;
}
-//void SwNodeNum::SetRestart(bool bRestart)
-//{
-// // --> OD 2005-10-19 #126009#
-// // - improvement: invalidation only, if <IsRestart()> state changes.
-// const bool bInvalidate( mbRestart != bRestart );
-// // <--
-// mbRestart = bRestart;
-
-// // --> OD 2005-10-19 #126009#
-// if ( bInvalidate )
-// {
-// InvalidateMe();
-// NotifyInvalidSiblings();
-// }
-// // <--
-//}
-
bool SwNodeNum::IsRestart() const
{
bool bIsRestart = false;
@@ -312,22 +285,6 @@ bool SwNodeNum::IsRestart() const
return bIsRestart;
}
-//void SwNodeNum::SetStart(SwNumberTree::tSwNumTreeNumber nStart)
-//{
-// // --> OD 2005-10-19 #126009#
-// // - improvement: invalidation only, if <IsRestart()> state changes.
-// const bool bInvalidate( mnStart != nStart );
-// // <--
-// mnStart = nStart;
-
-// // --> OD 2005-10-19 #126009#
-// if ( bInvalidate )
-// {
-// InvalidateMe();
-// NotifyInvalidSiblings();
-// }
-//}
-
bool SwNodeNum::IsCountPhantoms() const
{
bool bResult = true;
@@ -376,62 +333,6 @@ SwNumberTree::tSwNumTreeNumber SwNodeNum::GetStartValue() const
return aResult;
}
-//String SwNodeNum::ToString() const
-//{
-// String aResult("[ ", RTL_TEXTENCODING_ASCII_US);
-
-// if (GetTxtNode())
-// {
-// char aBuffer[256];
-
-// sprintf(aBuffer, "%p ", GetTxtNode());
-
-// aResult += String(aBuffer, RTL_TEXTENCODING_ASCII_US);
-// aResult += String::CreateFromInt32(GetPosition().nNode.GetIndex());
-// }
-// else
-// aResult += String("*", RTL_TEXTENCODING_ASCII_US);
-
-// aResult += String(" ", RTL_TEXTENCODING_ASCII_US);
-
-// unsigned int nLvl = GetLevel();
-// aResult += String::CreateFromInt32(nLvl);
-
-// aResult += String(": ", RTL_TEXTENCODING_ASCII_US);
-
-// tNumberVector aNumVector;
-
-// _GetNumberVector(aNumVector, false);
-
-// for (unsigned int n = 0; n < aNumVector.size(); n++)
-// {
-// if (n > 0)
-// aResult += String(", ", RTL_TEXTENCODING_ASCII_US);
-
-// aResult += String::CreateFromInt32(aNumVector[n]);
-// }
-
-// if (IsCounted())
-//// aResult += String(" counted", RTL_TEXTENCODING_ASCII_US);
-// aResult += String(" C", RTL_TEXTENCODING_ASCII_US);
-
-// if (IsRestart())
-// {
-//// aResult += String(" restart(", RTL_TEXTENCODING_ASCII_US);
-// aResult += String(" R(", RTL_TEXTENCODING_ASCII_US);
-// aResult += String::CreateFromInt32(GetStart());
-// aResult += String(")", RTL_TEXTENCODING_ASCII_US);
-// }
-
-// if (! IsValid())
-//// aResult += String(" invalid", RTL_TEXTENCODING_ASCII_US);
-// aResult += String(" I", RTL_TEXTENCODING_ASCII_US);
-
-// aResult += String(" ]", RTL_TEXTENCODING_ASCII_US);
-
-// return aResult;
-//}
-
// --> OD 2006-03-07 #131436#
void SwNodeNum::HandleNumberTreeRootNodeDelete( SwNodeNum& rNodeNum )
{
@@ -508,8 +409,6 @@ const SwNodeNum* SwNodeNum::GetPrecedingNodeNumOf( const SwTxtNode& rTxtNode ) c
const SwNodeNum* pPrecedingNodeNum( 0 );
// --> OD 2007-10-31 #i83479#
-// SwNodeNum aNodeNumForTxtNode;
-// aNodeNumForTxtNode.SetTxtNode( const_cast<SwTxtNode*>(&rTxtNode) );
SwNodeNum aNodeNumForTxtNode( const_cast<SwTxtNode*>(&rTxtNode) );
// <--
diff --git a/sw/source/core/SwNumberTree/SwNumberTree.cxx b/sw/source/core/SwNumberTree/SwNumberTree.cxx
index ec691a02c182..0014bfda530d 100644
--- a/sw/source/core/SwNumberTree/SwNumberTree.cxx
+++ b/sw/source/core/SwNumberTree/SwNumberTree.cxx
@@ -172,23 +172,6 @@ void SwNumberTreeNode::ValidateHierarchical(const SwNumberTreeNode * pNode) cons
// of the previous node determines the start value for the following
// children loop, if all children have to be validated and the first
// one doesn't restart the counting.
-// tSwNumTreeNumber nTmpNumber = 0;
-// if (aIt != mChildren.end())
-// nTmpNumber = (*aIt)->mnNumber;
-// while (aIt != aValidateIt)
-// {
-// if (aIt == mChildren.end())
-// aIt = mChildren.begin();
-// else
-// {
-// aIt++;
-// if ((*aIt)->IsCounted())
-// nTmpNumber++;
-// }
-// if ((*aIt)->IsRestart() || aIt == mChildren.begin())
-// nTmpNumber = (*aIt)->GetStart();
-// (*aIt)->mnNumber = nTmpNumber;
-// }
SwNumberTree::tSwNumTreeNumber nTmpNumber( 0 );
if (aIt != mChildren.end())
nTmpNumber = (*aIt)->mnNumber;
@@ -342,7 +325,6 @@ void SwNumberTreeNode::ValidateContinuous(const SwNumberTreeNode * pNode) const
// --> OD 2008-05-21 #i74748# - applied patch from garnier_romain
// number tree node has to be validated.
-// SetLastValid(aIt);
SetLastValid( aIt, true );
// <--
}
@@ -1052,32 +1034,6 @@ SwNumberTreeNode::GetIterator(const SwNumberTreeNode * pChild) const
return aItResult;
}
-//String SwNumberTreeNode::print(const String & rIndent,
-// const String & rMyIndent,
-// int nDepth) const
-//{
-// String aStr = rIndent;
-// aStr += ToString();
-// aStr += String("\n", RTL_TEXTENCODING_ASCII_US);
-
-// if (nDepth != 0)
-// {
-// if (nDepth < 0)
-// nDepth = -1;
-
-// tSwNumberTreeChildren::const_iterator aIt;
-// for (aIt = mChildren.begin(); aIt != mChildren.end(); aIt++)
-// {
-// String aTmpStr(rIndent);
-
-// aTmpStr += rMyIndent;
-// aStr += (*aIt)->print(aTmpStr, rMyIndent, nDepth - 1);
-// }
-// }
-
-// return aStr;
-//}
-
#if OSL_DEBUG_LEVEL > 1
unsigned long SwNumberTreeNode::GetInstances()
{