summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editeng/source/xml/xmltxtimp.cxx17
1 files changed, 17 insertions, 0 deletions
diff --git a/editeng/source/xml/xmltxtimp.cxx b/editeng/source/xml/xmltxtimp.cxx
index 23fc2bec007f..fd757e86493c 100644
--- a/editeng/source/xml/xmltxtimp.cxx
+++ b/editeng/source/xml/xmltxtimp.cxx
@@ -103,10 +103,27 @@ public:
const css::uno::Reference< css::uno::XComponentContext >& rContext,
const uno::Reference< XText > & rText );
+ virtual SvXMLImportContext *CreateContext( sal_uInt16 nPrefix,
+ const OUString& rLocalName, const uno::Reference< xml::sax::XAttributeList >& xAttrList ) override;
+
private:
const uno::Reference< XText > mxText;
};
+SvXMLImportContext *SvxXMLXTextImportComponent::CreateContext( sal_uInt16 nPrefix, const OUString& rLocalName, const uno::Reference< xml::sax::XAttributeList >& xAttrList )
+{
+ SvXMLImportContext* pContext = nullptr;
+
+ if(XML_NAMESPACE_OFFICE == nPrefix && IsXMLToken( rLocalName, XML_DOCUMENT_CONTENT ) )
+ {
+ pContext = new SvxXMLTextImportContext( *this, nPrefix, rLocalName, xAttrList, mxText );
+ }
+
+ if( nullptr == pContext )
+ pContext = new SvXMLImportContext( *this, nPrefix, rLocalName );
+
+ return pContext;
+}
SvxXMLXTextImportComponent::SvxXMLXTextImportComponent(
const css::uno::Reference< css::uno::XComponentContext >& xContext,