sw/source/core/docnode/section.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
New commits: commit c0ad522e37888daed9a6486c41f1d6a444aacb3d Author: László Németh <nem...@numbertext.org> AuthorDate: Fri Jan 24 00:12:39 2025 +0100 Commit: Adolfo Jayme Barrientos <fit...@ubuntu.com> CommitDate: Thu Feb 6 06:33:09 2025 +0100 tdf#121119 master docs at-page anchor: clean-up renaming Add file name only to the objects anchored at page, not to all of them. Follow-up to commit 2f135fa82c5d78ddafc14f38c0ee33358075b266 "tdf#121119 master docs at-page anchor: fix missing images", commit fb4197ed81765e122b862471e184fcade4a2b524 "tdf#121119 master docs at-page anchor: fix duplicated images" and commit 47d596688f2dcdf67fab24e58d92f823e69c0c35 "tdf#121119 master docs at-page anchor: fix runtime duplicated images". Change-Id: If851818731e87225d53370978a92c02cfb5d7189 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180678 Tested-by: Jenkins Reviewed-by: László Németh <nem...@numbertext.org> (cherry picked from commit d023f4ef363cf284cf93f1687e960b0121dcfae2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/180827 Reviewed-by: Adolfo Jayme Barrientos <fit...@ubuntu.com> diff --git a/sw/source/core/docnode/section.cxx b/sw/source/core/docnode/section.cxx index 84bf46e9fbad..4b38e8fa258a 100644 --- a/sw/source/core/docnode/section.cxx +++ b/sw/source/core/docnode/section.cxx @@ -1258,13 +1258,13 @@ static void lcl_UpdateLinksInSect( const SwBaseLink& rUpdLnk, SwSectionNode& rSe sal_uInt32 nPrevPages = 0; for( sw::SpzFrameFormat* pCpyFormat: *pSrcFormats) { - // add file name of the source document to the name of the copied object - // Note: used for the recognition of the copied objects anchored at page - pCpyFormat->SetFormatName( pCpyFormat->GetName() + " (" + sFileName + ")" ); - SwFormatAnchor aAnchor( pCpyFormat->GetAnchor() ); if ( RndStdIds::FLY_AT_PAGE == aAnchor.GetAnchorId() ) { + // add file name of the source document to the name of the copied object + // Note: used for the recognition of the copied objects anchored at page + pCpyFormat->SetFormatName( pCpyFormat->GetName() + " (" + sFileName + ")" ); + // sum page counts of the previous sections if ( nPrevPages == 0 ) {