From 51f00abe7a17c91476375babaa69f4c7b1883c09 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 1 Jul 2021 12:26:35 +0200 Subject: 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 Reviewed-by: Noel Grandin --- include/svl/style.hxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/svl') 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 #include +#include // 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 GetItemSetForPreview(); + virtual std::optional GetItemSetForPreview(); /// Fix for expensive dynamic_cast virtual bool isScStyleSheet() const { return false; } -- cgit