From e1383444c6d00f5d0b1d507670517f45988b9cc7 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 7 Jan 2020 13:01:41 +0200 Subject: extract some common code from ImportContext classes which reduces code bloat, and lets us log when elements are ignored Change-Id: I5ca12bc1fcbfa3bea49ebde819fd80bd233a96a0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86338 Tested-by: Jenkins Reviewed-by: Noel Grandin --- editeng/source/misc/SvXMLAutoCorrectImport.cxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'editeng/source/misc') diff --git a/editeng/source/misc/SvXMLAutoCorrectImport.cxx b/editeng/source/misc/SvXMLAutoCorrectImport.cxx index 0e93089acfba..fb64d57c024f 100644 --- a/editeng/source/misc/SvXMLAutoCorrectImport.cxx +++ b/editeng/source/misc/SvXMLAutoCorrectImport.cxx @@ -61,8 +61,7 @@ css::uno::Reference SAL_CALL SvXMLWordListContext::createFa { if ( Element == SvXMLAutoCorrectToken::BLOCK ) return new SvXMLWordContext (rLocalRef, xAttrList); - else - return new SvXMLImportContext( rLocalRef ); + return nullptr; } SvXMLWordListContext::~SvXMLWordListContext() @@ -135,8 +134,7 @@ css::uno::Reference SAL_CALL SvXMLExceptionListCo { if ( Element == SvXMLAutoCorrectToken::BLOCK ) return new SvXMLExceptionContext (rLocalRef, xAttrList); - else - return new SvXMLImportContext( rLocalRef ); + return nullptr; } SvXMLExceptionListContext::~SvXMLExceptionListContext() -- cgit