diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2019-07-31 20:50:05 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-08-01 10:23:34 +0200 |
commit | 97185d833c8dc75032ff73cbf597635b32c5f5fb (patch) | |
tree | 5fa9055af9b5d009a782b6a40d22a1a38496b76d /xmloff | |
parent | 26c2cea1ab0efeb3ea641c335472e411dab2e928 (diff) |
xmloff: create XMLImpressStylesExportOOO instances with an uno constructor
See tdf#74608 for motivation.
Change-Id: I6b99c5975eacbaba5dbec1ae679c9e5726bdfd6b
Reviewed-on: https://gerrit.libreoffice.org/76766
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/inc/facreg.hxx | 5 | ||||
-rw-r--r-- | xmloff/source/core/facreg.cxx | 1 | ||||
-rw-r--r-- | xmloff/source/draw/sdxmlexp.cxx | 11 | ||||
-rw-r--r-- | xmloff/util/xo.component | 3 |
4 files changed, 12 insertions, 8 deletions
diff --git a/xmloff/inc/facreg.hxx b/xmloff/inc/facreg.hxx index 7cb149cac9f1..e96ed09d04af 100644 --- a/xmloff/inc/facreg.hxx +++ b/xmloff/inc/facreg.hxx @@ -39,11 +39,6 @@ css::uno::Sequence<OUString> XMLImpressExportOOO_getSupportedServiceNames() thro /// @throws css::uno::Exception css::uno::Reference<css::uno::XInterface> XMLImpressExportOOO_createInstance( css::uno::Reference<css::lang::XMultiServiceFactory> const & rSMgr); -OUString XMLImpressStylesExportOOO_getImplementationName() throw(); -css::uno::Sequence<OUString> XMLImpressStylesExportOOO_getSupportedServiceNames() throw(); -/// @throws css::uno::Exception -css::uno::Reference<css::uno::XInterface> XMLImpressStylesExportOOO_createInstance( - css::uno::Reference<css::lang::XMultiServiceFactory> const & rSMgr); OUString XMLImpressContentExportOOO_getImplementationName() throw(); css::uno::Sequence<OUString> XMLImpressContentExportOOO_getSupportedServiceNames() throw(); /// @throws css::uno::Exception diff --git a/xmloff/source/core/facreg.cxx b/xmloff/source/core/facreg.cxx index 0190e6b0d818..38d5cfb29ac5 100644 --- a/xmloff/source/core/facreg.cxx +++ b/xmloff/source/core/facreg.cxx @@ -60,7 +60,6 @@ XMLOFF_DLLPUBLIC void * xo_component_getFactory( const sal_Char * pImplName, voi // impress OOo export else SINGLEFACTORY( XMLImpressExportOOO ) - else SINGLEFACTORY( XMLImpressStylesExportOOO ) else SINGLEFACTORY( XMLImpressContentExportOOO ) else SINGLEFACTORY( XMLImpressMetaExportOOO ) else SINGLEFACTORY( XMLImpressSettingsExportOOO ) diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx index 182fa660a119..017eebeb0a12 100644 --- a/xmloff/source/draw/sdxmlexp.cxx +++ b/xmloff/source/draw/sdxmlexp.cxx @@ -2657,8 +2657,17 @@ com_sun_star_comp_Impress_XMLOasisSettingsExporter_get_implementation( SvXMLExportFlags::OASIS | SvXMLExportFlags::SETTINGS)); } +extern "C" SAL_DLLPUBLIC_EXPORT uno::XInterface* +com_sun_star_comp_Impress_XMLStylesExporter_get_implementation( + uno::XComponentContext* pCtx, uno::Sequence<uno::Any> const& /*rSeq*/) +{ + return cppu::acquire(new SdXMLExport(pCtx, "XMLImpressStylesExportOOO", false, + SvXMLExportFlags::STYLES | SvXMLExportFlags::MASTERSTYLES + | SvXMLExportFlags::AUTOSTYLES + | SvXMLExportFlags::FONTDECLS)); +} + SERVICE( XMLImpressExportOOO, "com.sun.star.comp.Impress.XMLExporter", "XMLImpressExportOOO", false, SvXMLExportFlags::META|SvXMLExportFlags::STYLES|SvXMLExportFlags::MASTERSTYLES|SvXMLExportFlags::AUTOSTYLES|SvXMLExportFlags::CONTENT|SvXMLExportFlags::SCRIPTS|SvXMLExportFlags::SETTINGS|SvXMLExportFlags::FONTDECLS|SvXMLExportFlags::EMBEDDED ); -SERVICE( XMLImpressStylesExportOOO, "com.sun.star.comp.Impress.XMLStylesExporter", "XMLImpressStylesExportOOO", false, SvXMLExportFlags::STYLES|SvXMLExportFlags::MASTERSTYLES|SvXMLExportFlags::AUTOSTYLES|SvXMLExportFlags::FONTDECLS ); SERVICE( XMLImpressContentExportOOO, "com.sun.star.comp.Impress.XMLContentExporter", "XMLImpressContentExportOOO", false, SvXMLExportFlags::AUTOSTYLES|SvXMLExportFlags::CONTENT|SvXMLExportFlags::SCRIPTS|SvXMLExportFlags::FONTDECLS ); SERVICE( XMLImpressMetaExportOOO, "com.sun.star.comp.Impress.XMLMetaExporter", "XMLImpressMetaExportOOO", false, SvXMLExportFlags::META ); SERVICE( XMLImpressSettingsExportOOO, "com.sun.star.comp.Impress.XMLSettingsExporter", "XMLImpressSettingsExportOOO", false, SvXMLExportFlags::SETTINGS ); diff --git a/xmloff/util/xo.component b/xmloff/util/xo.component index 936b7b627103..69fc7c5b1845 100644 --- a/xmloff/util/xo.component +++ b/xmloff/util/xo.component @@ -148,7 +148,8 @@ constructor="com_sun_star_comp_Impress_XMLOasisSettingsImporter_get_implementation"> <service name="com.sun.star.comp.Impress.XMLOasisSettingsImporter"/> </implementation> - <implementation name="XMLImpressStylesExportOOO"> + <implementation name="XMLImpressStylesExportOOO" + constructor="com_sun_star_comp_Impress_XMLStylesExporter_get_implementation"> <service name="com.sun.star.comp.Impress.XMLStylesExporter"/> </implementation> <implementation name="XMLImpressStylesExportOasis" |