summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorKorrawit Pruegsanusak <detective.conan.1412@gmail.com>2013-11-26 22:45:07 +0700
committerThorsten Behrens <thb@documentfoundation.org>2013-12-03 03:44:28 -0600
commita06bc4102934c47e1aebe53ea24415fafb7c506a (patch)
tree9aedba7eaf814353c8caacab8afeec0ca8ffcabe /oox
parenta2b0ab0be7632a00ac59b778bd1108d1cdc48dc5 (diff)
fdo#71434: don't show master text if PlaceHolder types defined
I've added all of valid PlaceHolder types from http://www.schemacentral.com/sc/ooxml/t-p_ST_PlaceholderType.html (cherry picked from commit bb1213a740b3b3b2b1967639939dd7a72c6d4237) Change-Id: I038fe43ff83699f92ff5eb9945bce12540058478 Reviewed-on: https://gerrit.libreoffice.org/6822 Reviewed-by: Muthu Subramanian K <muthusuba@gmail.com> Tested-by: Muthu Subramanian K <muthusuba@gmail.com> Reviewed-by: Thorsten Behrens <thb@documentfoundation.org> Tested-by: Thorsten Behrens <thb@documentfoundation.org>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/ppt/pptgraphicshapecontext.cxx23
1 files changed, 20 insertions, 3 deletions
diff --git a/oox/source/ppt/pptgraphicshapecontext.cxx b/oox/source/ppt/pptgraphicshapecontext.cxx
index 99c7328d9952..730ce23967bf 100644
--- a/oox/source/ppt/pptgraphicshapecontext.cxx
+++ b/oox/source/ppt/pptgraphicshapecontext.cxx
@@ -147,9 +147,26 @@ ContextHandlerRef PPTGraphicShapeContext::onCreateContext( sal_Int32 aElementTok
if ( pPlaceholder.get() )
{
bool bUseText = true;
- // TODO: Check if pPlaceholder->getSubType is none (i.e. none explicitly specified)
- if( pPlaceholder->getSubType() == XML_obj )
- bUseText = false;
+ switch( pPlaceholder->getSubType() )
+ {
+ case XML_title :
+ case XML_body :
+ case XML_ctrTitle :
+ case XML_subTitle :
+ case XML_dt :
+ case XML_sldNum :
+ case XML_ftr :
+ case XML_hdr :
+ case XML_obj :
+ case XML_chart :
+ case XML_tbl :
+ case XML_clipArt :
+ case XML_dgm :
+ case XML_media :
+ case XML_sldImg :
+ case XML_pic :
+ bUseText = false;
+ }
mpShapePtr->applyShapeReference( *pPlaceholder.get(), bUseText );
PPTShape* pPPTShape = dynamic_cast< PPTShape* >( pPlaceholder.get() );
if ( pPPTShape )