diff options
author | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-08-11 10:46:53 +0100 |
---|---|---|
committer | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-08-11 18:12:47 +0200 |
commit | 5aeb15e95d26ce6de28eb5f5933324828d553f41 (patch) | |
tree | 02ec28c990d4c0caf2fbb8e89f192d94082be412 /sc/source | |
parent | de20853e5243843ac9f4c5927ce0b4cf0e407c15 (diff) |
refactor to return the position to be set by the caller instead
no change in behavior intended
Change-Id: I32043bdf1d29521d8503df315fa786236e272f7d
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155580
Tested-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'sc/source')
-rw-r--r-- | sc/source/filter/oox/commentsbuffer.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sc/source/filter/oox/commentsbuffer.cxx b/sc/source/filter/oox/commentsbuffer.cxx index 05deae3ee876..555ddad3a924 100644 --- a/sc/source/filter/oox/commentsbuffer.cxx +++ b/sc/source/filter/oox/commentsbuffer.cxx @@ -183,7 +183,12 @@ void Comment::finalizeImport() if( const ::oox::vml::ShapeBase* pVmlNoteShape = getVmlDrawing().getNoteShape( maModel.maRange.aStart ) ) { // position and formatting - pVmlNoteShape->convertFormatting( xAnnoShape ); + css::awt::Rectangle aShapeRect = pVmlNoteShape->convertFormatting(xAnnoShape); + if (aShapeRect.Width > 0 || aShapeRect.Height > 0) + { + xAnnoShape->setPosition(css::awt::Point(aShapeRect.X, aShapeRect.Y)); + xAnnoShape->setSize(css::awt::Size(aShapeRect.Width, aShapeRect.Height)); + } // visibility bVisible = pVmlNoteShape->getTypeModel().mbVisible; |