sw/qa/extras/odfexport/data/tdf118502.odt  |binary
 sw/qa/extras/odfexport/odfexport.cxx       |    8 ++++++++
 xmloff/source/core/xmlmultiimagehelper.cxx |    4 ++++
 3 files changed, 12 insertions(+)

New commits:
commit 005be0cd5ea4a16860ad595d03ab133daf709a33
Author:     Samuel Mehrbrodt <samuel.mehrbr...@cib.de>
AuthorDate: Wed Sep 19 12:51:00 2018 +0200
Commit:     Michael Stahl <michael.st...@cib.de>
CommitDate: Thu Sep 20 14:10:46 2018 +0200

    tdf#118502 Fix loading of eps images with replacement graphic
    
    Change-Id: Iaf9c8e2ed72115e1f82d2541ae2a1d4803795a46
    Reviewed-on: https://gerrit.libreoffice.org/60752
    Tested-by: Jenkins
    Reviewed-by: Samuel Mehrbrodt <samuel.mehrbr...@cib.de>
    (cherry picked from commit 088af44063c3e2d1d0e7744a9f9bd7b37ff58a75)
    Reviewed-on: https://gerrit.libreoffice.org/60768
    Reviewed-by: Michael Stahl <michael.st...@cib.de>

diff --git a/sw/qa/extras/odfexport/data/tdf118502.odt 
b/sw/qa/extras/odfexport/data/tdf118502.odt
new file mode 100644
index 000000000000..f006d607ac3b
Binary files /dev/null and b/sw/qa/extras/odfexport/data/tdf118502.odt differ
diff --git a/sw/qa/extras/odfexport/odfexport.cxx 
b/sw/qa/extras/odfexport/odfexport.cxx
index f26810175cd3..9aaa1c53c020 100644
--- a/sw/qa/extras/odfexport/odfexport.cxx
+++ b/sw/qa/extras/odfexport/odfexport.cxx
@@ -1770,6 +1770,14 @@ DECLARE_ODFEXPORT_TEST(testTdf77961, "tdf77961.odt")
     CPPUNIT_ASSERT_EQUAL( false , getProperty<bool>(xStyle, "GridPrint"));
 }
 
+DECLARE_ODFEXPORT_TEST(tdf118502, "tdf118502.odt")
+{
+    uno::Reference<drawing::XShape> xShape = getShape(1);
+    // Make sure the replacement graphic is still there
+    // (was gone because the original graphic was not recognized during load)
+    CPPUNIT_ASSERT(!getProperty<OUString>(xShape, 
"ReplacementGraphicURL").isEmpty());
+}
+
 #endif
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/xmloff/source/core/xmlmultiimagehelper.cxx 
b/xmloff/source/core/xmlmultiimagehelper.cxx
index 7213a5090f54..ccc92302ca7f 100644
--- a/xmloff/source/core/xmlmultiimagehelper.cxx
+++ b/xmloff/source/core/xmlmultiimagehelper.cxx
@@ -75,6 +75,10 @@ namespace
         {
             return 1020;
         }
+        if(sMimeType == "image/x-eps")
+        {
+            return 1025;
+        }
         if(sMimeType == "application/pdf")
         {
             return 1030;
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to