diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2020-12-13 15:40:41 +0100 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2020-12-13 16:48:48 +0100 |
commit | e7fb2c18e96d04ec54274721df003ab01f2064ab (patch) | |
tree | 8556e49ba8a1611d21946e94a62998ab852fa683 /xmloff | |
parent | c17ff0b5dc20d637392562eb59bd5bfdb2694389 (diff) |
Get rid of wrong warning in propertyexport (forms)
Create a brand new odt file, add an image with form Control then save
You'll notice this on console:
warn:legacy.osl:20299:20299:xmloff/source/forms/propertyexport.cxx:680: OPropertyExport::dbg_implCheckProperty: invalid property type!
it's wrong since most of the type the exported property should be a OUString (internal "string")
but it may also be a graphic::XGraphic and this case isn't dealt by DBG_CHECK_PROPERTY
since we only gave it "OUString()"
Change-Id: I268b8d5f79c84ea73acdac245ee1705ddd009ae9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107653
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
Diffstat (limited to 'xmloff')
-rw-r--r-- | xmloff/source/forms/propertyexport.cxx | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/xmloff/source/forms/propertyexport.cxx b/xmloff/source/forms/propertyexport.cxx index 86ef1db82ef0..74ea521322c6 100644 --- a/xmloff/source/forms/propertyexport.cxx +++ b/xmloff/source/forms/propertyexport.cxx @@ -386,8 +386,6 @@ namespace xmloff void OPropertyExport::exportRelativeTargetLocation(const OUString& _sPropertyName,CCAFlags _nProperty,bool _bAddType) { - DBG_CHECK_PROPERTY( _sPropertyName, OUString ); - Any aAny = m_xProps->getPropertyValue(_sPropertyName); OUString sTargetLocation; @@ -402,6 +400,11 @@ namespace xmloff auto sURL = aAny.get<OUString>(); sTargetLocation = m_rContext.getGlobalContext().AddEmbeddedObject(sURL); } + else + { + SAL_WARN("xmloff.forms", "OPropertyExport::exportRelativeTargetLocation: " + "Value of " << _sPropertyName << " not found!"); + } if (!sTargetLocation.isEmpty()) { |