summaryrefslogtreecommitdiff
path: root/xmloff/source/draw/ximpstyl.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2024-10-18 21:39:46 +0200
committerCaolán McNamara <caolan.mcnamara@collabora.com>2024-10-21 15:49:38 +0200
commitea7cf71ad297e55750eb3df3f9eee9aca906d22c (patch)
tree6f519e87f6dcfaee7be8d0465a8ccc35da9b3529 /xmloff/source/draw/ximpstyl.cxx
parentabe6ab7aec0993dd54746d9f0c743fc42cf7ce79 (diff)
only set parent style name if necessary
a similar mega-master-page scenario as reported in tdf#158773 17s - 13.5s Change-Id: Ic20fc0a269ce59094732b1ea5292b24a18777a2d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175180 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'xmloff/source/draw/ximpstyl.cxx')
-rw-r--r--xmloff/source/draw/ximpstyl.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/xmloff/source/draw/ximpstyl.cxx b/xmloff/source/draw/ximpstyl.cxx
index 2014ea5aec8c..b3b0bc8978d3 100644
--- a/xmloff/source/draw/ximpstyl.cxx
+++ b/xmloff/source/draw/ximpstyl.cxx
@@ -1374,7 +1374,8 @@ void SdXMLStylesContext::ImpSetGraphicStyles( uno::Reference< container::XNameAc
sParentStyleDisplayName = sParentStyleDisplayName.copy( nPrefLen );
}
- xStyle->setParentStyle( sParentStyleDisplayName );
+ if (xStyle->getParentStyle() != sParentStyleDisplayName)
+ xStyle->setParentStyle( sParentStyleDisplayName );
}
}
catch( const Exception& e )