summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
Diffstat (limited to 'oox')
-rw-r--r--oox/source/export/chartexport.cxx10
-rw-r--r--oox/source/export/shapes.cxx2
2 files changed, 2 insertions, 10 deletions
diff --git a/oox/source/export/chartexport.cxx b/oox/source/export/chartexport.cxx
index 41faecacdbdb..b1e9368d7c7a 100644
--- a/oox/source/export/chartexport.cxx
+++ b/oox/source/export/chartexport.cxx
@@ -452,12 +452,6 @@ ChartExport::ChartExport( sal_Int32 nXmlNamespace, FSHelperPtr pFS, Reference< f
{
}
-sal_Int32 ChartExport::GetChartID( )
-{
- sal_Int32 nID = GetFB()->GetUniqueId();
- return nID;
-}
-
sal_Int32 ChartExport::getChartType( )
{
OUString sChartType = mxDiagram->getDiagramType();
@@ -509,7 +503,7 @@ OUString ChartExport::parseFormula( const OUString& rRange )
return aResult;
}
-void ChartExport::WriteChartObj( const Reference< XShape >& xShape, sal_Int32 nChartCount )
+void ChartExport::WriteChartObj( const Reference< XShape >& xShape, sal_Int32 nID, sal_Int32 nChartCount )
{
FSHelperPtr pFS = GetFS();
@@ -523,8 +517,6 @@ void ChartExport::WriteChartObj( const Reference< XShape >& xShape, sal_Int32 nC
if (xNamed.is())
sName = xNamed->getName();
- sal_Int32 nID = GetChartID();
-
pFS->singleElementNS( mnXmlNamespace, XML_cNvPr,
XML_id, I32S( nID ),
XML_name, USS( sName ),
diff --git a/oox/source/export/shapes.cxx b/oox/source/export/shapes.cxx
index c9661684535e..871873c968b1 100644
--- a/oox/source/export/shapes.cxx
+++ b/oox/source/export/shapes.cxx
@@ -1941,7 +1941,7 @@ ShapeExport& ShapeExport::WriteOLE2Shape( const Reference< XShape >& xShape )
Reference< XModel > xModel( xChartDoc, UNO_QUERY );
ChartExport aChartExport( mnXmlNamespace, GetFS(), xModel, GetFB(), GetDocumentType() );
static sal_Int32 nChartCount = 0;
- aChartExport.WriteChartObj( xShape, ++nChartCount );
+ aChartExport.WriteChartObj( xShape, GetNewShapeID( xShape ), ++nChartCount );
return *this;
}