offapi/com/sun/star/style/NumberingLevel.idl | 8 ++++---- sw/qa/extras/ooxmlexport/ooxmlexport2.cxx | 8 ++++---- sw/qa/extras/rtfexport/rtfexport.cxx | 9 +++++---- sw/source/core/unocore/unosett.cxx | 3 --- 4 files changed, 13 insertions(+), 15 deletions(-)
New commits: commit 84f30b34bf63dba8d5b478edac684bee5a841100 Author: Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk> Date: Thu May 17 20:17:53 2018 +0900 [API-CHANGE] change to GraphicBitmap prop. for NumberingLevel To make it consistent, change "Graphic" property (added during image handling rework) to "GraphicBitmap" in style::NumberingLevel, which is already used in text::NumberingLevel. Both of them are accessors for the graphic of bitmap bullets. Change-Id: I70f7bccd80fa9949778c49e23de583c6fb32a796 Reviewed-on: https://gerrit.libreoffice.org/54492 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Tomaž Vajngerl <qui...@gmail.com> diff --git a/offapi/com/sun/star/style/NumberingLevel.idl b/offapi/com/sun/star/style/NumberingLevel.idl index c7e700cc63d1..eb3cb92add03 100644 --- a/offapi/com/sun/star/style/NumberingLevel.idl +++ b/offapi/com/sun/star/style/NumberingLevel.idl @@ -67,8 +67,8 @@ published service NumberingLevel Note the new behaviour since it this was deprecated: This property can only be set and only external URLs are supported (no more vnd.sun.star.GraphicObject scheme). When an - URL is set, then it will load the graphic and set the Graphic - property. + URL is set, then it will load the graphic and set the + GraphicBitmap property. */ [property] string GraphicURL; @@ -76,11 +76,11 @@ published service NumberingLevel */ [property] short StartWith; - /** This is the graphic file to use as a symbol. + /** This is the graphic bitmap to use as a symbol. @since LibreOffice 6.1 */ - [optional, property] com::sun::star::graphic::XGraphic Graphic; + [optional, property] com::sun::star::awt::XBitmap GraphicBitmap; }; diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx index a4b4bfec4b9a..95218dae815f 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx @@ -603,7 +603,7 @@ DECLARE_OOXMLEXPORT_TEST(testI120928, "i120928.docx") uno::Sequence<beans::PropertyValue> aProps; xLevels->getByIndex(0) >>= aProps; // 1st level - uno::Reference<graphic::XGraphic> xGraphic; + uno::Reference<awt::XBitmap> xBitmap; sal_Int16 nNumberingType = -1; for (int i = 0; i < aProps.getLength(); ++i) @@ -612,11 +612,11 @@ DECLARE_OOXMLEXPORT_TEST(testI120928, "i120928.docx") if (rProp.Name == "NumberingType") nNumberingType = rProp.Value.get<sal_Int16>(); - else if (rProp.Name == "Graphic") - xGraphic = rProp.Value.get<uno::Reference<graphic::XGraphic>>(); + else if (rProp.Name == "GraphicBitmap") + xBitmap = rProp.Value.get<uno::Reference<awt::XBitmap>>(); } CPPUNIT_ASSERT_EQUAL(style::NumberingType::BITMAP, nNumberingType); - CPPUNIT_ASSERT(xGraphic.is()); + CPPUNIT_ASSERT(xBitmap.is()); } DECLARE_OOXMLEXPORT_TEST(testFdo64826, "fdo64826.docx") diff --git a/sw/qa/extras/rtfexport/rtfexport.cxx b/sw/qa/extras/rtfexport/rtfexport.cxx index 5f1b96b01ebb..c69529438e30 100644 --- a/sw/qa/extras/rtfexport/rtfexport.cxx +++ b/sw/qa/extras/rtfexport/rtfexport.cxx @@ -10,6 +10,7 @@ #include <swmodeltestbase.hxx> #include <com/sun/star/awt/Gradient.hpp> +#include <com/sun/star/awt/XBitmap.hpp> #include <com/sun/star/document/XDocumentPropertiesSupplier.hpp> #include <com/sun/star/drawing/EnhancedCustomShapeParameterPair.hpp> #include <com/sun/star/drawing/FillStyle.hpp> @@ -552,7 +553,7 @@ DECLARE_RTFEXPORT_TEST(testI120928, "i120928.rtf") uno::Sequence<beans::PropertyValue> aProps; xLevels->getByIndex(0) >>= aProps; // 1st level - uno::Reference<graphic::XGraphic> xGraphic; + uno::Reference<awt::XBitmap> xBitmap; sal_Int16 nNumberingType = -1; for (int i = 0; i < aProps.getLength(); ++i) @@ -561,11 +562,11 @@ DECLARE_RTFEXPORT_TEST(testI120928, "i120928.rtf") if (rProp.Name == "NumberingType") nNumberingType = rProp.Value.get<sal_Int16>(); - else if (rProp.Name == "Graphic") - xGraphic = rProp.Value.get<uno::Reference<graphic::XGraphic>>(); + else if (rProp.Name == "GraphicBitmap") + xBitmap = rProp.Value.get<uno::Reference<awt::XBitmap>>(); } CPPUNIT_ASSERT_EQUAL(style::NumberingType::BITMAP, nNumberingType); - CPPUNIT_ASSERT(xGraphic.is()); + CPPUNIT_ASSERT(xBitmap.is()); } DECLARE_RTFEXPORT_TEST(testBookmark, "bookmark.rtf") diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx index c0894cef4ccc..e27cc31c0780 100644 --- a/sw/source/core/unocore/unosett.cxx +++ b/sw/source/core/unocore/unosett.cxx @@ -1431,9 +1431,6 @@ uno::Sequence<beans::PropertyValue> SwXNumberingRules::GetPropertiesForNumFormat const Graphic* pGraphic = pBrush ? pBrush->GetGraphic() : nullptr; if (pGraphic) { - uno::Reference<graphic::XGraphic> xGraphic(pGraphic->GetXGraphic()); - //GraphicURL - aPropertyValues.push_back(comphelper::makePropertyValue(UNO_NAME_GRAPHIC, xGraphic)); //GraphicBitmap uno::Reference<awt::XBitmap> xBitmap(pGraphic->GetXGraphic(), uno::UNO_QUERY); aPropertyValues.push_back(comphelper::makePropertyValue(UNO_NAME_GRAPHIC_BITMAP, xBitmap)); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits