sw/source/core/edit/edfcol.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
New commits: commit db3d90abd3bb830b079169397f656c56bdcc3af8 Author: Vasily Melenchuk <vasily.melenc...@cib.de> AuthorDate: Thu Apr 30 16:27:37 2020 +0300 Commit: Thorsten Behrens <thorsten.behr...@cib.de> CommitDate: Mon May 4 22:48:12 2020 +0200 sw: moved setting shape name to earlier stage During setting of some shape properties undo/redo code is called. Undo/redo code should know about shape and style name. Change-Id: I5240c450d0c739a245e32e9ca6f34518f35ddda5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93214 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <thorsten.behr...@cib.de> diff --git a/sw/source/core/edit/edfcol.cxx b/sw/source/core/edit/edfcol.cxx index f6804b0db3c4..6ecde0f71c77 100644 --- a/sw/source/core/edit/edfcol.cxx +++ b/sw/source/core/edit/edfcol.cxx @@ -1522,6 +1522,10 @@ static void lcl_placeWatermarkInHeader(const SfxWatermarkItem& rWatermark, // Create and insert the shape. uno::Reference<drawing::XShape> xShape(xMultiServiceFactory->createInstance(aShapeServiceName), uno::UNO_QUERY); + + uno::Reference<container::XNamed> xNamed(xShape, uno::UNO_QUERY); + xNamed->setName(sWatermark); + basegfx::B2DHomMatrix aTransformation; aTransformation.identity(); aTransformation.scale(nWidth, nHeight); @@ -1590,8 +1594,6 @@ static void lcl_placeWatermarkInHeader(const SfxWatermarkItem& rWatermark, xPropertySet->setPropertyValue(UNO_NAME_HORI_ORIENT, uno::makeAny(text::HoriOrientation::CENTER)); xPropertySet->setPropertyValue(UNO_NAME_VERT_ORIENT, uno::makeAny(text::VertOrientation::CENTER)); - uno::Reference<container::XNamed> xNamed(xShape, uno::UNO_QUERY); - xNamed->setName(sWatermark); xLockable->removeActionLock(); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits