summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2017-05-19 16:21:48 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2017-05-19 18:56:18 +0200
commit9b261681e5325e3fb7c87653de8e367ec18486c9 (patch)
tree9dd71135729394cc09b223e8682c34467e0dd40b /sw
parentb6778e921f72ca0ef49b4e18f3f990a397b9c491 (diff)
svtools: fix mime type of PDF images
Otherwise the UNO API user can only see this image has a replacement, but not possible to say if it's an SVG or a PDF image. Change-Id: Ibde7915e02620acecbbb237dc3b333382d9c784a Reviewed-on: https://gerrit.libreoffice.org/37827 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/odfexport/odfexport.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/sw/qa/extras/odfexport/odfexport.cxx b/sw/qa/extras/odfexport/odfexport.cxx
index a8a8812508b5..13b9a368fb02 100644
--- a/sw/qa/extras/odfexport/odfexport.cxx
+++ b/sw/qa/extras/odfexport/odfexport.cxx
@@ -1210,6 +1210,11 @@ DECLARE_ODFEXPORT_TEST(testEmbeddedPdf, "embedded-pdf.odt")
// This failed, pdf+png replacement graphics pair didn't survive an ODT roundtrip.
CPPUNIT_ASSERT(!getProperty<OUString>(xShape, "ReplacementGraphicURL").isEmpty());
+ auto xGraphic = getProperty< uno::Reference<graphic::XGraphic> >(xShape, "Graphic");
+ CPPUNIT_ASSERT(xGraphic.is());
+ // This was image/x-vclgraphic, not exposing the info that the image is a PDF one.
+ CPPUNIT_ASSERT_EQUAL(OUString("application/pdf"), getProperty<OUString>(xGraphic, "MimeType"));
+
if (mbExported)
{
uno::Sequence<uno::Any> aArgs(1);