summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2017-02-10 16:41:55 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2017-02-10 19:07:06 +0000
commit8c6776f27cef1e2b7b40957f1801b08707bc3230 (patch)
treee83ec93fe47c3c71b8505fe6b602778ee6824f85 /oox
parente530c7c4bcaaeb99cecd6f3c2c303db2a114b555 (diff)
Related: tdf#105707 PPTX import: warn on empty SmartArt fallback
This second related situation is about when there is drawingML fallback for the SmartArt, but it's ampty shape tree, which is never created with MSO2010+ (those shape trees always have at least one element). This is as bad as the missing drawingML fallback, so warn on it. Change-Id: I539d05154a4d1fcd5871dfc29616f77eb9945454 Reviewed-on: https://gerrit.libreoffice.org/34131 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/ppt/extdrawingfragmenthandler.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/oox/source/ppt/extdrawingfragmenthandler.cxx b/oox/source/ppt/extdrawingfragmenthandler.cxx
index 72b33ff83c9e..7d1a3cf6a4a7 100644
--- a/oox/source/ppt/extdrawingfragmenthandler.cxx
+++ b/oox/source/ppt/extdrawingfragmenthandler.cxx
@@ -11,6 +11,7 @@
#include <oox/token/namespaces.hxx>
#include <oox/token/tokens.hxx>
+#include <oox/core/xmlfilterbase.hxx>
using namespace ::oox::core;
using namespace ::com::sun::star::xml::sax;
@@ -35,7 +36,9 @@ ExtDrawingFragmentHandler::ExtDrawingFragmentHandler( XmlFilterBase& rFilter,
ExtDrawingFragmentHandler::~ExtDrawingFragmentHandler( ) throw ()
{
-
+ // Empty DrawingML fallback, need to warn the user at the end.
+ if (mpShapePtr && mpShapePtr->getChildren().empty())
+ getFilter().setMissingExtDrawing();
}
ContextHandlerRef