diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2023-02-23 23:38:08 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2023-03-01 12:57:29 +0000 |
commit | 6e8c67580974484c790f52991de26298ce8e7e1c (patch) | |
tree | 0dc731c89810fa9c8d40de9c1b8cedc99a6dcf9c /include | |
parent | 855f7c08d1feab7669670bfbc4ed2b3b3225db16 (diff) |
oox: import directly into docmodel's Theme and ColorSet
This changes the import to directly fill values of a model::Theme
and model::ColorSet, without filling the oox structs first. The
goal is to get rid of the oox in the long run, but for now it is
necessary to keep reading into both, which is a duplication.
The next step is to also fill the FontScheme and FormatScheme
structures.
Change-Id: I488ec096cbc184bc70d24510ac9091a488540422
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/147571
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/oox/drawingml/themefragmenthandler.hxx | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/include/oox/drawingml/themefragmenthandler.hxx b/include/oox/drawingml/themefragmenthandler.hxx index 918a3eb861b9..5c193544fe65 100644 --- a/include/oox/drawingml/themefragmenthandler.hxx +++ b/include/oox/drawingml/themefragmenthandler.hxx @@ -25,29 +25,28 @@ #include <oox/dllapi.h> #include <rtl/ustring.hxx> #include <sal/types.h> +#include <docmodel/theme/Theme.hxx> namespace oox { class AttributeList; } namespace oox::core { class XmlFilterBase; } -namespace oox::drawingml { +namespace oox::drawingml +{ class Theme; - class OOX_DLLPUBLIC ThemeFragmentHandler final : public ::oox::core::FragmentHandler2 { public: - explicit ThemeFragmentHandler( - ::oox::core::XmlFilterBase& rFilter, - const OUString& rFragmentPath, - Theme& rTheme ); - virtual ~ThemeFragmentHandler() override; + explicit ThemeFragmentHandler(::oox::core::XmlFilterBase& rFilter, const OUString& rFragmentPath, Theme& rOoxTheme, model::Theme& rTheme); + virtual ~ThemeFragmentHandler() override; - virtual ::oox::core::ContextHandlerRef onCreateContext( sal_Int32 nElement, const AttributeList& rAttribs ) override; + virtual ::oox::core::ContextHandlerRef onCreateContext(sal_Int32 nElement, const AttributeList& rAttribs) override; void onStartElement(const AttributeList& rAttribs) override; private: - Theme& mrTheme; + Theme& mrOoxTheme; + model::Theme& mrTheme; }; |