summaryrefslogtreecommitdiffstats
path: root/chart2/source/view/main/ShapeFactory.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'chart2/source/view/main/ShapeFactory.cxx')
-rw-r--r--chart2/source/view/main/ShapeFactory.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/chart2/source/view/main/ShapeFactory.cxx b/chart2/source/view/main/ShapeFactory.cxx
index 7fddc5d018d5..8f9f29ced232 100644
--- a/chart2/source/view/main/ShapeFactory.cxx
+++ b/chart2/source/view/main/ShapeFactory.cxx
@@ -2533,16 +2533,17 @@ void ShapeFactory::removeSubShapes( const rtl::Reference<SvxShapeGroupAnyD>& xSh
}
rtl::Reference<SvxTableShape>
-ShapeFactory::createTable(rtl::Reference<SvxShapeGroupAnyD> const& xTarget)
+ShapeFactory::createTable(rtl::Reference<SvxShapeGroupAnyD> const& xTarget, OUString const& rName)
{
- if( !xTarget.is() )
+ if (!xTarget.is())
return nullptr;
//create table shape
rtl::Reference<SvxTableShape> xShape = new SvxTableShape(nullptr);
xShape->setShapeKind(SdrObjKind::Table);
xTarget->addShape(*xShape);
-
+ if (!rName.isEmpty())
+ setShapeName(xShape, rName);
return xShape;
}