diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2018-02-19 21:47:04 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2018-02-21 21:32:56 +0100 |
commit | e48b4275ceee82bd0eb128b2947302b9022e9c89 (patch) | |
tree | c40d1d0d100c67c7fc8076e34b9d8e0769638d37 /include/xmloff/xmlexp.hxx | |
parent | 6fc75b669438728ba6a4e55d53a79fa0cf006529 (diff) |
report the saved mimetype when saving graphic + mime from stream
When saving we need to determine which mime type to use for the
graphic. Return this information back to the caller so the
metadata can be written into the file if necessary.
Also add function to determine the mime type from the XGraphic
by converting it to a stream first (only then we can determine the
format that will actually be used and written to the storage file.
Change-Id: I796da715e47f29d77dea605a2769a2217ecd6ba5
Reviewed-on: https://gerrit.libreoffice.org/49992
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include/xmloff/xmlexp.hxx')
-rw-r--r-- | include/xmloff/xmlexp.hxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/xmloff/xmlexp.hxx b/include/xmloff/xmlexp.hxx index 2d367b433935..cfea8a19a5e9 100644 --- a/include/xmloff/xmlexp.hxx +++ b/include/xmloff/xmlexp.hxx @@ -463,9 +463,9 @@ public: OUString AddEmbeddedGraphicObject( const OUString& rGraphicObjectURL ); - OUString AddEmbeddedXGraphic(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic, OUString const & rRequestedName = OUString()); + OUString AddEmbeddedXGraphic(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic, OUString & rOutMimeType, OUString const & rRequestedName = OUString()); bool AddEmbeddedXGraphicAsBase64(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic); - css::uno::Reference<css::io::XInputStream> GetEmbeddedXGraphicStream(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic); + bool GetGraphicMimeTypeFromStream(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic, OUString & rOutMimeType); css::uno::Reference<css::io::XInputStream> GetEmbeddedGraphicObjectStream( const OUString& rGraphicObjectURL); |