summaryrefslogtreecommitdiff
path: root/sw/source/core/doc
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/doc')
-rw-r--r--sw/source/core/doc/doctxm.cxx6
1 files changed, 5 insertions, 1 deletions
diff --git a/sw/source/core/doc/doctxm.cxx b/sw/source/core/doc/doctxm.cxx
index a25a6d61e62b..e7b908222367 100644
--- a/sw/source/core/doc/doctxm.cxx
+++ b/sw/source/core/doc/doctxm.cxx
@@ -1286,7 +1286,11 @@ void SwTOXBaseSection::UpdateSequence( const SwTxtNode* pOwnChapterNode )
( !IsFromChapter() ||
::lcl_FindChapterNode( rTxtNode, 0 ) == pOwnChapterNode ) )
{
- SwTOXPara * pNew = new SwTOXPara( rTxtNode, nsSwTOXElement::TOX_SEQUENCE, 1 );
+ const SwSetExpField* pSeqField = dynamic_cast< const SwSetExpField* >( pFmtFld->GetFld() );
+ OUString sName = GetSequenceName();
+ sName += OUString( cSequenceMarkSeparator );
+ sName += OUString::valueOf( sal_Int32( pSeqField->GetSeqNumber() ) );
+ SwTOXPara * pNew = new SwTOXPara( rTxtNode, nsSwTOXElement::TOX_SEQUENCE, 1, sName );
// set indexes if the number or the reference text are to be displayed
if( GetCaptionDisplay() == CAPTION_TEXT )
{