diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/svtools/embedhlp.hxx | 2 | ||||
-rw-r--r-- | include/unotools/streamwrap.hxx | 3 | ||||
-rw-r--r-- | include/unotools/ucbstreamhelper.hxx | 15 | ||||
-rw-r--r-- | include/vcl/graphicfilter.hxx | 2 |
4 files changed, 13 insertions, 9 deletions
diff --git a/include/svtools/embedhlp.hxx b/include/svtools/embedhlp.hxx index 30a5cdc6338e..27e3e89eb590 100644 --- a/include/svtools/embedhlp.hxx +++ b/include/svtools/embedhlp.hxx @@ -48,7 +48,7 @@ class SVT_DLLPUBLIC EmbeddedObjectRef { std::unique_ptr<EmbeddedObjectRef_Impl> mpImpl; - SVT_DLLPRIVATE SvStream* GetGraphicStream( bool bUpdate ) const; + SVT_DLLPRIVATE std::unique_ptr<SvStream> GetGraphicStream( bool bUpdate ) const; SVT_DLLPRIVATE void GetReplacement( bool bUpdate ); EmbeddedObjectRef& operator = ( const EmbeddedObjectRef& ) = delete; diff --git a/include/unotools/streamwrap.hxx b/include/unotools/streamwrap.hxx index 81f463ea6e2c..299b6dfd081f 100644 --- a/include/unotools/streamwrap.hxx +++ b/include/unotools/streamwrap.hxx @@ -29,6 +29,7 @@ #include <com/sun/star/io/XStream.hpp> #include <cppuhelper/implbase.hxx> #include <cppuhelper/implbase1.hxx> +#include <memory> class SvStream; @@ -53,6 +54,7 @@ protected: public: OInputStreamWrapper(SvStream& _rStream); OInputStreamWrapper(SvStream* pStream, bool bOwner=false); + OInputStreamWrapper(std::unique_ptr<SvStream> pStream); virtual ~OInputStreamWrapper() override; // css::io::XInputStream @@ -152,6 +154,7 @@ protected: public: OStreamWrapper(SvStream& _rStream); + OStreamWrapper(std::unique_ptr<SvStream> _rStream); // css::io::XStream virtual css::uno::Reference< css::io::XInputStream > SAL_CALL getInputStream( ) override; diff --git a/include/unotools/ucbstreamhelper.hxx b/include/unotools/ucbstreamhelper.hxx index 68309d094acf..f037571fe212 100644 --- a/include/unotools/ucbstreamhelper.hxx +++ b/include/unotools/ucbstreamhelper.hxx @@ -25,6 +25,7 @@ #include <unotools/unotoolsdllapi.h> #include <tools/stream.hxx> +#include <memory> namespace com { @@ -52,13 +53,13 @@ namespace utl class UNOTOOLS_DLLPUBLIC UcbStreamHelper { public: - static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode ); - static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode, - bool bFileExists ); - static SvStream* CreateStream( const css::uno::Reference < css::io::XInputStream >& xStream ); - static SvStream* CreateStream( const css::uno::Reference < css::io::XStream >& xStream ); - static SvStream* CreateStream( const css::uno::Reference < css::io::XInputStream >& xStream, bool bCloseStream ); - static SvStream* CreateStream( const css::uno::Reference < css::io::XStream >& xStream, bool bCloseStream ); + static std::unique_ptr<SvStream> CreateStream( const OUString& rFileName, StreamMode eOpenMode ); + static std::unique_ptr<SvStream> CreateStream( const OUString& rFileName, StreamMode eOpenMode, + bool bFileExists ); + static std::unique_ptr<SvStream> CreateStream( const css::uno::Reference < css::io::XInputStream >& xStream ); + static std::unique_ptr<SvStream> CreateStream( const css::uno::Reference < css::io::XStream >& xStream ); + static std::unique_ptr<SvStream> CreateStream( const css::uno::Reference < css::io::XInputStream >& xStream, bool bCloseStream ); + static std::unique_ptr<SvStream> CreateStream( const css::uno::Reference < css::io::XStream >& xStream, bool bCloseStream ); }; } diff --git a/include/vcl/graphicfilter.hxx b/include/vcl/graphicfilter.hxx index 2f24cf10e085..8c5ce93221f2 100644 --- a/include/vcl/graphicfilter.hxx +++ b/include/vcl/graphicfilter.hxx @@ -285,7 +285,7 @@ public: /// Imports multiple graphics. /// /// The resulting graphic is added to rGraphics on success, nullptr is added on failure. - void ImportGraphics(std::vector< std::shared_ptr<Graphic> >& rGraphics, const std::vector< std::shared_ptr<SvStream> >& rStreams); + void ImportGraphics(std::vector< std::shared_ptr<Graphic> >& rGraphics, std::vector< std::unique_ptr<SvStream> > vStreams); ErrCode ImportGraphic( Graphic& rGraphic, const OUString& rPath, SvStream& rStream, |