From 25b642fdd87da4d5ed556600d0eb69d72865f666 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Mon, 1 Apr 2024 20:52:59 +0200 Subject: simplify SotTempStream and lifetime It is really just an SvStream instance, and the lifetime does not need reference counting Change-Id: Idb5ffd96f852aae0dc1a94cddc0a83fbcdf974ff Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165655 Tested-by: Jenkins Reviewed-by: Noel Grandin --- include/sot/storage.hxx | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'include/sot/storage.hxx') diff --git a/include/sot/storage.hxx b/include/sot/storage.hxx index 2a49b4a39475..39246b779a29 100644 --- a/include/sot/storage.hxx +++ b/include/sot/storage.hxx @@ -35,15 +35,9 @@ enum class SotClipboardFormatId : sal_uInt32; class BaseStorageStream; -class SOT_DLLPUBLIC SotTempStream final : virtual public SvRefBase, public SvStream +namespace SotTempStream { -friend class SotStorage; - - virtual ~SotTempStream() override; -public: - SotTempStream(OUString const & rString, StreamMode = StreamMode::STD_READWRITE); - - void CopyTo(SotTempStream * pDestStm); + SOT_DLLPUBLIC std::unique_ptr Create(OUString const & rString, StreamMode = StreamMode::STD_READWRITE); }; class SOT_DLLPUBLIC SotStorageStream final : virtual public SotObject, public SvStream -- cgit