summaryrefslogtreecommitdiff
path: root/include/svl
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-07-01 12:26:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-07-02 15:53:15 +0200
commit51f00abe7a17c91476375babaa69f4c7b1883c09 (patch)
treea327834dfa25e31425e58b657e9b8d887acee74e /include/svl
parent2024780f9e169a6c1d167e494d37f46f7640dc97 (diff)
no need to allocate return val on heap for GetItemSetForPreview
Change-Id: I261182ec2348df045171c5e1beb33579e2c0c766 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118284 Tested-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include/svl')
-rw-r--r--include/svl/style.hxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/svl/style.hxx b/include/svl/style.hxx
index 735e3607242d..b3db632c4841 100644
--- a/include/svl/style.hxx
+++ b/include/svl/style.hxx
@@ -37,6 +37,7 @@
#include <tools/solar.h>
#include <memory>
+#include <optional>
// This is used as a flags enum in sw/, but only there,
// so I don't pull in o3tl::typed_flags here
@@ -178,7 +179,7 @@ public:
/// preview only; it shall not create the style in case it does not exist.
/// If the style has parents, it is _not_ required that the returned item
/// set has parents (i.e. use it for display purposes only).
- virtual std::unique_ptr<SfxItemSet> GetItemSetForPreview();
+ virtual std::optional<SfxItemSet> GetItemSetForPreview();
/// Fix for expensive dynamic_cast
virtual bool isScStyleSheet() const { return false; }