diff options
author | Noel <noelgrandin@gmail.com> | 2020-10-23 15:12:22 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-11-02 08:17:00 +0100 |
commit | 8c5ffecf1dbd3f93128910433da11d5315661680 (patch) | |
tree | 4263d40f2e6e118f42b7eed7bc40e92ad504036d /starmath | |
parent | 0f3a8a972421aa440f4276b92463a481e5cd4267 (diff) |
make SvXMLImport capable of mixing fast- and slow- contexts adhoc
so I can convert even *ImportContext subclasses in the middle of
a context stack, and thus break the cyclic dependency nature
of the writer import.
and adjust the xmlimport loplugin for the new rules.
As a consequence of the loplugin:xmlimport's checking, we remove
a bunch of now unnecessary overrides of startFastElement.
Change-Id: I97464522ede8ec5e345e928cdafa4b18364b1b80
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104730
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/source/mathmlimport.cxx | 41 |
1 files changed, 0 insertions, 41 deletions
diff --git a/starmath/source/mathmlimport.cxx b/starmath/source/mathmlimport.cxx index 2f8dfb4aeab2..675081ef574e 100644 --- a/starmath/source/mathmlimport.cxx +++ b/starmath/source/mathmlimport.cxx @@ -518,8 +518,6 @@ public: virtual void TCharacters(const OUString & /*rChars*/); virtual void SAL_CALL characters(const OUString &rChars) override; - virtual uno::Reference< xml::sax::XFastContextHandler > SAL_CALL createFastChildContext( - sal_Int32 nElement, const uno::Reference< xml::sax::XFastAttributeList >& xAttrList ) override; virtual void SAL_CALL startFastElement(sal_Int32 /*nElement*/, const css::uno::Reference<css::xml::sax::XFastAttributeList>& /*rAttrList*/) override { if (GetSmImport().TooDeep()) @@ -547,12 +545,6 @@ void SmXMLImportContext::characters(const OUString &rChars) TCharacters(rChars2/*.collapse()*/); } -uno::Reference< xml::sax::XFastContextHandler > SAL_CALL SmXMLImportContext::createFastChildContext( - sal_Int32 /*nElement*/, const uno::Reference< xml::sax::XFastAttributeList >& /*xAttrList*/ ) -{ - return nullptr; -} - namespace { struct SmXMLContext_Helper @@ -1859,9 +1851,6 @@ public: {} /*Don't do anything with alignment for now*/ - void SAL_CALL endFastElement(sal_Int32 ) override - { - } }; @@ -1888,13 +1877,6 @@ public: SmXMLOfficeContext_Impl( SmXMLImport &rImport ) : SvXMLImportContext(rImport) {} - virtual void SAL_CALL characters( const OUString& /*aChars*/ ) override {} - - virtual void SAL_CALL startFastElement( sal_Int32 /*nElement*/, - const css::uno::Reference< css::xml::sax::XFastAttributeList >& /*xAttrList*/ ) override {} - - virtual void SAL_CALL endFastElement( sal_Int32 /*nElement*/ ) override {} - virtual css::uno::Reference< css::xml::sax::XFastContextHandler > SAL_CALL createFastChildContext( sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttrList ) override; }; @@ -1925,13 +1907,6 @@ public: SmXMLFlatDocContext_Impl( SmXMLImport& i_rImport, const uno::Reference<document::XDocumentProperties>& i_xDocProps); - virtual void SAL_CALL characters( const OUString& aChars ) override; - - virtual void SAL_CALL startFastElement( sal_Int32 nElement, - const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttrList ) override; - - virtual void SAL_CALL endFastElement( sal_Int32 nElement ) override; - virtual css::uno::Reference< css::xml::sax::XFastContextHandler > SAL_CALL createFastChildContext( sal_Int32 nElement, const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttrList ) override; }; @@ -1946,22 +1921,6 @@ SmXMLFlatDocContext_Impl::SmXMLFlatDocContext_Impl( SmXMLImport& i_rImport, { } -void SAL_CALL SmXMLFlatDocContext_Impl::startFastElement( sal_Int32 nElement, - const uno::Reference< xml::sax::XFastAttributeList >& xAttrList ) -{ - SvXMLMetaDocumentContext::startFastElement(nElement, xAttrList); -} - -void SAL_CALL SmXMLFlatDocContext_Impl::endFastElement( sal_Int32 nElement ) -{ - SvXMLMetaDocumentContext::endFastElement(nElement); -} - -void SAL_CALL SmXMLFlatDocContext_Impl::characters( const OUString& rChars ) -{ - SvXMLMetaDocumentContext::characters(rChars); -} - uno::Reference< xml::sax::XFastContextHandler > SAL_CALL SmXMLFlatDocContext_Impl::createFastChildContext( sal_Int32 nElement, const uno::Reference< xml::sax::XFastAttributeList >& xAttrList ) { |