Fix PageShape export to pptx
The export code is not called, because the PageShape is actually
of type presentation.PageShape and not drawing.PageShape. A
PageShape has no text at all, which results in an empty p:txBody
element that fails validation, so it needs to be checked first if
the shape actually has text.
Change-Id: I559f15c2396739c74d5c4f36eb952754bc040ce8
Reviewed-on: https://gerrit.libreoffice.org/38574
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
diff --git a/oox/source/export/shapes.cxx b/oox/source/export/shapes.cxx
index 810391e..4775b1b 100644
--- a/oox/source/export/shapes.cxx
+++ b/oox/source/export/shapes.cxx
@@ -1445,7 +1445,8 @@ ShapeExport& ShapeExport::WriteTextBox( const Reference< XInterface >& xIface, s
}
}
if( NonEmptyText( xIface ) )
Reference< XText > xXText( xIface, UNO_QUERY );
if( NonEmptyText( xIface ) && xXText.is() )
{
FSHelperPtr pFS = GetFS();
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index b0e2b23..227291f 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -302,7 +302,7 @@ ShapeExport& PowerPointShapeExport::WriteUnknownShape( const Reference< XShape >
mrExport.EnterGroup( rXIndexAccess );
SAL_INFO("sd.eppt", "enter group");
}
else if ( sShapeType == "com.sun.star.drawing.PageShape" )
else if ( sShapeType == "com.sun.star.presentation.PageShape" )
{
WritePageShape( xShape, mePageType, mrExport.GetPresObj() );
}