diff options
author | Michael Stahl <mstahl@redhat.com> | 2013-08-26 14:59:45 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2013-08-26 15:12:47 +0200 |
commit | 2395ae8d2ecb5b527d8856ddbce4831a6d2a7092 (patch) | |
tree | 95e6dd9efa0c6dab30f87daa60e0d21126a468dd | |
parent | ee41ad3482011b3e736b8bbd51353f71b2369dfb (diff) |
fdo#33960: simplify SwNumRule::MakeRefNumString further
Change-Id: Ib0e9ccb163d5132ca18142361f72376642915fcb
-rw-r--r-- | sw/source/core/doc/number.cxx | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/sw/source/core/doc/number.cxx b/sw/source/core/doc/number.cxx index 7b8d77399ace..ffd471b7a313 100644 --- a/sw/source/core/doc/number.cxx +++ b/sw/source/core/doc/number.cxx @@ -730,7 +730,6 @@ OUString SwNumRule::MakeRefNumString( const SwNodeNum& rNodeNum, if ( rNodeNum.GetLevelInListTree() >= 0 ) { bool bOldHadPrefix = true; - OUString sOldPrefix; const SwNodeNum* pWorkingNodeNum( &rNodeNum ); do @@ -772,21 +771,9 @@ OUString SwNumRule::MakeRefNumString( const SwNodeNum& rNodeNum, !aExtremities.nPrefixChars ) { - nStrip = 0; - while (nStrip < aExtremities.nSuffixChars) - { - ++nStrip; - } - if (nStrip) - { - aPrevStr = aPrevStr.copy(0, aPrevStr.getLength()-nStrip); - } - } - else if (!aExtremities.nSuffixChars && !bOldHadPrefix) - { - aRefNumStr = sOldPrefix + aRefNumStr; + aPrevStr = aPrevStr.copy(0, + aPrevStr.getLength() - aExtremities.nSuffixChars); } - sOldPrefix = OUString(); bOldHadPrefix = ( aExtremities.nPrefixChars > 0); |