summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2024-06-28 12:24:40 +0200
committerMiklos Vajna <vmiklos@collabora.com>2024-06-28 18:12:10 +0200
commit94094d86883ea78e3b09d1d237e9f1b757ec0136 (patch)
treea6c2bd976f926c6b897a1b906e46d618a5180b34
parentb17171b949fed99c55c35bcb8203129c8fef41f1 (diff)
oox, drawingml: use more bLineShape in Shape::createAndInsert()
As suggested at <https://gerrit.libreoffice.org/c/core/+/169615/1#message-39aa9a1b288ff3a7459fc68c09d10c312efbaa33>. Change-Id: I72f9cc905f18a48dcae2cf4b96d4560ad0a6080b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169701 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
-rw-r--r--oox/source/drawingml/shape.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index 5adf4a8eb15b..4c7de78b8817 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -1039,8 +1039,7 @@ Reference< XShape > const & Shape::createAndInsert(
bool bTopWriterLine = !pParentGroupShape && mbWps && bLineShape;
// Build object matrix from shape size and position; corresponds to MSO ext and off
// Only LineShape and ConnectorShape may have zero width or height.
- if (aServiceName == "com.sun.star.drawing.LineShape"
- || aServiceName == "com.sun.star.drawing.ConnectorShape")
+ if (bLineShape || aServiceName == "com.sun.star.drawing.ConnectorShape")
{
// For toplevel Writer lines, size is included in the point coordinates.
if (!bTopWriterLine)
@@ -1178,7 +1177,7 @@ Reference< XShape > const & Shape::createAndInsert(
}
// special for lineshape
- if ( aServiceName == "com.sun.star.drawing.LineShape" )
+ if (bLineShape)
{
::basegfx::B2DPolygon aPoly;
aPoly.insert( 0, ::basegfx::B2DPoint( 0, 0 ) );