summaryrefslogtreecommitdiff
path: root/include/comphelper
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2017-11-29 21:12:32 +0100
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2017-11-30 17:42:42 +0100
commit32efde5cef2b8516a9decd0bf7091d7def1da971 (patch)
treed92e02b3834b08b8e02ef8ca7adfcd2ded509107 /include/comphelper
parentb17c29d493a1fc588524d6da332254fbb959f0db (diff)
tdf#113696 Add mimetype to image element
Otherwise browsers don't recognize base64 encoded svg files. Change-Id: I54d0b87c52a1ca9da1d820751ae32159b88ed28f Reviewed-on: https://gerrit.libreoffice.org/45528 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'include/comphelper')
-rw-r--r--include/comphelper/graphicmimetype.hxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/comphelper/graphicmimetype.hxx b/include/comphelper/graphicmimetype.hxx
index 3f2b5308b2d6..970342f2e5f5 100644
--- a/include/comphelper/graphicmimetype.hxx
+++ b/include/comphelper/graphicmimetype.hxx
@@ -13,12 +13,20 @@
#include <comphelper/comphelperdllapi.h>
#include <rtl/ustring.hxx>
+#include <com/sun/star/graphic/XGraphic.hpp>
+#include <com/sun/star/io/XInputStream.hpp>
+#include <com/sun/star/uno/Reference.hxx>
+
namespace comphelper
{
class COMPHELPER_DLLPUBLIC GraphicMimeTypeHelper
{
public:
static OUString GetMimeTypeForExtension(const OString& rExt);
+ static OUString GetMimeTypeForXGraphic(css::uno::Reference<css::graphic::XGraphic> xGraphic);
+ static OUString GetMimeTypeForImageUrl(const OUString& rImageUrl);
+ static OUString
+ GetMimeTypeForImageStream(css::uno::Reference<css::io::XInputStream> xInputStream);
};
}