summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2023-05-03 22:58:47 +0900
committerTomaž Vajngerl <quikee@gmail.com>2023-05-09 08:25:53 +0200
commit8bafae3656f7a0a6b74bb0985403a96f9a3f61be (patch)
tree41d874ea7223f3e59e672d9feb61f4415058055d /include
parent5c5d0c4858a123c6aa1dbadcdfd96641eb91283b (diff)
change model::ColorSet to be stored in a shared_ptr in model::Theme
Change-Id: Ic3067f1681c047cd944e64179c568f4e972e0c95 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/151447 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include')
-rw-r--r--include/docmodel/theme/Theme.hxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/docmodel/theme/Theme.hxx b/include/docmodel/theme/Theme.hxx
index 9a5c9fe6ed5a..4643f0d0b33a 100644
--- a/include/docmodel/theme/Theme.hxx
+++ b/include/docmodel/theme/Theme.hxx
@@ -158,7 +158,7 @@ class DOCMODEL_DLLPUBLIC Theme
{
private:
OUString maName;
- std::unique_ptr<model::ColorSet> mpColorSet;
+ std::shared_ptr<model::ColorSet> mpColorSet;
FontScheme maFontScheme = FontScheme::getDefault();
FormatScheme maFormatScheme;
@@ -176,9 +176,9 @@ public:
FormatScheme const& getFormatScheme() const { return maFormatScheme; }
FormatScheme& getFormatScheme() { return maFormatScheme; }
- void SetColorSet(std::unique_ptr<ColorSet> pColorSet);
- const ColorSet* GetColorSet() const;
- ColorSet* GetColorSet();
+ void setColorSet(std::shared_ptr<model::ColorSet> const& pColorSet) { mpColorSet = pColorSet; }
+
+ std::shared_ptr<model::ColorSet> const& getColorSet() const { return mpColorSet; }
void SetName(const OUString& rName);
const OUString& GetName() const;