[Libreoffice-commits] core.git: xmloff/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Fri Aug 28 12:34:06 UTC 2020
xmloff/source/draw/ximpstyl.cxx | 56 ----------------------------------------
xmloff/source/draw/ximpstyl.hxx | 6 ----
2 files changed, 62 deletions(-)
New commits:
commit f697189b6965b3df744a87ee40a2ccd09a39af92
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Fri Aug 28 11:23:29 2020 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Fri Aug 28 14:33:20 2020 +0200
remove dead code in SdXMLHeaderFooterDeclContext
Change-Id: I58e3f3a4a02ebcb24b7e975e30e57d8b57cd52dc
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101533
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/xmloff/source/draw/ximpstyl.cxx b/xmloff/source/draw/ximpstyl.cxx
index 70082c166c68..7d6435ab024b 100644
--- a/xmloff/source/draw/ximpstyl.cxx
+++ b/xmloff/source/draw/ximpstyl.cxx
@@ -1388,40 +1388,6 @@ SvXMLImportContextRef SdXMLMasterStylesContext::CreateChildContext(
return xContext;
}
-SdXMLHeaderFooterDeclContext::SdXMLHeaderFooterDeclContext(SvXMLImport& rImport,
- sal_uInt16 nPrfx, const OUString& rLName,
- const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList)
- : SvXMLStyleContext( rImport, nPrfx, rLName, xAttrList)
- , mbFixed(false)
-{
- const sal_Int16 nAttrCount = xAttrList.is() ? xAttrList->getLength() : 0;
- for(sal_Int16 i=0; i < nAttrCount; i++)
- {
- OUString aLocalName;
- const OUString aValue( xAttrList->getValueByIndex(i) );
- sal_uInt16 nPrefix = GetImport().GetNamespaceMap().GetKeyByAttrName(xAttrList->getNameByIndex(i), &aLocalName);
-
- if( nPrefix == XML_NAMESPACE_PRESENTATION )
- {
- if( IsXMLToken( aLocalName, XML_NAME ) )
- {
- maStrName = aValue;
- }
- else if( IsXMLToken( aLocalName, XML_SOURCE ) )
- {
- mbFixed = IsXMLToken( aValue, XML_FIXED );
- }
- }
- else if( nPrefix == XML_NAMESPACE_STYLE )
- {
- if( IsXMLToken( aLocalName, XML_DATA_STYLE_NAME ) )
- {
- maStrDateTimeFormat = aValue;
- }
- }
- }
-}
-
SdXMLHeaderFooterDeclContext::SdXMLHeaderFooterDeclContext(SvXMLImport& rImport,
const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttrList)
: SvXMLStyleContext( rImport )
@@ -1476,28 +1442,6 @@ void SdXMLHeaderFooterDeclContext::endFastElement(sal_Int32 nToken)
}
}
-void SdXMLHeaderFooterDeclContext::EndElement()
-{
- SdXMLImport& rImport = dynamic_cast<SdXMLImport&>(GetImport());
- if( IsXMLToken( GetLocalName(), XML_HEADER_DECL ) )
- {
- rImport.AddHeaderDecl( maStrName, maStrText );
- }
- else if( IsXMLToken( GetLocalName(), XML_FOOTER_DECL ) )
- {
- rImport.AddFooterDecl( maStrName, maStrText );
- }
- else if( IsXMLToken( GetLocalName(), XML_DATE_TIME_DECL ) )
- {
- rImport.AddDateTimeDecl( maStrName, maStrText, mbFixed, maStrDateTimeFormat );
- }
-}
-
-void SdXMLHeaderFooterDeclContext::Characters( const OUString& rChars )
-{
- maStrText += rChars;
-}
-
void SdXMLHeaderFooterDeclContext::characters( const OUString& rChars )
{
maStrText += rChars;
diff --git a/xmloff/source/draw/ximpstyl.hxx b/xmloff/source/draw/ximpstyl.hxx
index 761927133797..7d0d94080411 100644
--- a/xmloff/source/draw/ximpstyl.hxx
+++ b/xmloff/source/draw/ximpstyl.hxx
@@ -239,16 +239,10 @@ public:
class SdXMLHeaderFooterDeclContext : public SvXMLStyleContext
{
public:
- // Can be called in either fast- or slow-parser mode
- SdXMLHeaderFooterDeclContext( SvXMLImport& rImport, sal_uInt16 nPrfx,
- const OUString& rLName,
- const css::uno::Reference< css::xml::sax::XAttributeList >& xAttrList );
SdXMLHeaderFooterDeclContext( SvXMLImport& rImport,
const css::uno::Reference< css::xml::sax::XFastAttributeList >& xAttrList );
virtual bool IsTransient() const override;
- virtual void EndElement() override;
- virtual void Characters( const OUString& rChars ) override;
virtual void SAL_CALL startFastElement(
sal_Int32 /*nElement*/,
const css::uno::Reference< css::xml::sax::XFastAttributeList >& ) override {}
More information about the Libreoffice-commits
mailing list