diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2004-03-30 15:06:01 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2004-03-30 15:06:01 +0000 |
commit | db780f759b0a7f8b0cd03c06582a220d7bcc629f (patch) | |
tree | 469f5af65f699423efe315d79dd65fb3749dfc78 /sw | |
parent | 5d57fe30c0075441c7ae48d4764e7d70c4ac92db (diff) |
INTEGRATION: CWS num03 (1.7.182); FILE MERGED
2004/03/29 13:36:11 hbrinkm 1.7.182.5: #115901#
2004/03/23 17:17:39 hbrinkm 1.7.182.4: #115901#
2004/03/22 09:55:11 hbrinkm 1.7.182.3: #115901#
2004/03/15 17:54:52 hbrinkm 1.7.182.2: RESYNC: (1.7-1.8); FILE MERGED
2004/03/15 16:56:26 hbrinkm 1.7.182.1: #115901#
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/docnode/ndnum.cxx | 41 |
1 files changed, 26 insertions, 15 deletions
diff --git a/sw/source/core/docnode/ndnum.cxx b/sw/source/core/docnode/ndnum.cxx index de38c25511..c7899fc327 100644 --- a/sw/source/core/docnode/ndnum.cxx +++ b/sw/source/core/docnode/ndnum.cxx @@ -2,9 +2,9 @@ * * $RCSfile: ndnum.cxx,v $ * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * - * last change: $Author: hr $ $Date: 2004-03-08 12:25:26 $ + * last change: $Author: rt $ $Date: 2004-03-30 16:06:01 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -238,8 +238,9 @@ BOOL _OutlinePara::UpdateOutline( SwTxtNode& rTxtNd ) { BOOL bTmpNoNum = ! aNum.IsNum(); aNum.SetNoNum( TRUE ); - rTxtNd.UpdateOutlineNum( aNum ); + rTxtNd.UpdateNum( aNum ); // #115901# aNum.SetNoNum( bTmpNoNum ); + return TRUE; } @@ -302,7 +303,7 @@ BOOL _OutlinePara::UpdateOutline( SwTxtNode& rTxtNd ) aNum.GetLevelVal()[ nLevel ] = nSetValue; aNum.SetLevel( nLevel ); - rTxtNd.UpdateOutlineNum( aNum ); + rTxtNd.UpdateNum( aNum ); aNum.SetSetValue( USHRT_MAX ); } return bRet; @@ -358,6 +359,7 @@ void SwNodes::UpdateOutlineNode( const SwNode& rNd, BYTE nOldLevel, else if( !bSeekIdx ) // Update und Index nicht gefunden ?? return ; +#if 0 if (GetDoc()->IsOldNumbering()) { _OutlinePara aPara( *this, nSttPos, nOldLevel, nNewLevel ); @@ -384,20 +386,29 @@ void SwNodes::UpdateOutlineNode( const SwNode& rNd, BYTE nOldLevel, } else // #111955# +#endif { SwTxtNode & rTxtNd = (SwTxtNode &) rNd; + SwPaM aPam(rTxtNd); // #115901# - const SwNodeNum * pNum = rTxtNd.GetOutlineNum(); - - SwNodeNum aNum(0); - - if (0 != pNum) - aNum = *pNum; - - aNum.SetLevel(rTxtNd.GetTxtColl()->GetOutlineLevel()); - rTxtNd.UpdateOutlineNum(aNum); - - GetDoc()->UpdateNumRule(*GetDoc()->GetOutlineNumRule(), 0, TRUE); + if (nNewLevel != NO_NUMBERING) // #115901# + { + const SwNodeNum * pNum = rTxtNd.GetOutlineNum(); + + SwNodeNum aNum(0); + + if (0 != pNum) + aNum = *pNum; + + aNum.SetLevel(rTxtNd.GetTxtColl()->GetOutlineLevel()); + rTxtNd.UpdateNum(aNum); + + GetDoc()->SetNumRule(aPam, *GetDoc()->GetOutlineNumRule()); + } + else + { + GetDoc()->DelNumRules(aPam); + } } // die Gliederungs-Felder Updaten |