summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorSarper Akdemir <sarper.akdemir@collabora.com>2021-05-09 20:08:47 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2021-06-23 11:48:06 +0200
commitcfc46a1a5703785eda258a4cfec02941df2ec9c6 (patch)
tree75d75cb9bdbfc29f91bebea6262e6e41e8359411 /oox
parent68eff384f6783fbae35c2e363fd4a17dda9c3772 (diff)
tdf#59323: ooxml import: hasNonInheritedShapeProperties
Introduces hasNonInheritedShapeProperties helper to PPTShape. If the shape has something imported from it's spPr tag mbHasNoninheritedShapeProperties set to true. Change-Id: I0529f1def8d2c32d5bf06172ce44facdde92893c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117003 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117620 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/ppt/pptshape.cxx1
-rw-r--r--oox/source/ppt/pptshapepropertiescontext.cxx5
2 files changed, 6 insertions, 0 deletions
diff --git a/oox/source/ppt/pptshape.cxx b/oox/source/ppt/pptshape.cxx
index e326cba50464..bd47dd0fae7a 100644
--- a/oox/source/ppt/pptshape.cxx
+++ b/oox/source/ppt/pptshape.cxx
@@ -48,6 +48,7 @@ PPTShape::PPTShape( const oox::ppt::ShapeLocation eShapeLocation, const char* pS
: Shape( pServiceName )
, meShapeLocation( eShapeLocation )
, mbReferenced( false )
+, mbHasNoninheritedShapeProperties( false )
{
}
diff --git a/oox/source/ppt/pptshapepropertiescontext.cxx b/oox/source/ppt/pptshapepropertiescontext.cxx
index 128272054b21..70ef2fcef872 100644
--- a/oox/source/ppt/pptshapepropertiescontext.cxx
+++ b/oox/source/ppt/pptshapepropertiescontext.cxx
@@ -20,6 +20,7 @@
#include <oox/ppt/pptshapepropertiescontext.hxx>
#include <oox/token/namespaces.hxx>
#include <oox/token/properties.hxx>
+#include <oox/ppt/pptshape.hxx>
using namespace oox::core;
using namespace ::com::sun::star;
@@ -35,6 +36,10 @@ PPTShapePropertiesContext::PPTShapePropertiesContext( ContextHandler2Helper cons
ContextHandlerRef PPTShapePropertiesContext::onCreateContext( sal_Int32 aElementToken, const AttributeList& rAttribs )
{
+ PPTShape* pPPTShape = dynamic_cast<PPTShape*>(&mrShape);
+ if (pPPTShape)
+ pPPTShape->setHasNoninheritedShapeProperties();
+
switch( aElementToken )
{
case A_TOKEN( xfrm ):