summaryrefslogtreecommitdiff
path: root/xmloff
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2016-10-06 17:26:44 +0200
committerEike Rathke <erack@redhat.com>2016-10-06 20:55:28 +0000
commita5442b696697e4a24566b1f5b7e5c9bc77a9fd03 (patch)
tree989ed9b2f781fae584a03392b138e4e7dd27fae3 /xmloff
parentff085ed8fd6438d855526a8a4d699960e4d3cc73 (diff)
rtl::math::approxEqual(value,0.0) never yields true for value!=0.0
... so replace with a simple value == 0.0 also in other modules than sc. Change-Id: Ie7316505a1cf9c15100114b45d300facceb03b7e Reviewed-on: https://gerrit.libreoffice.org/29575 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'xmloff')
-rw-r--r--xmloff/source/style/numehelp.cxx4
-rw-r--r--xmloff/source/text/txtflde.cxx2
2 files changed, 3 insertions, 3 deletions
diff --git a/xmloff/source/style/numehelp.cxx b/xmloff/source/style/numehelp.cxx
index 84288edf105c..9c437ce6f47e 100644
--- a/xmloff/source/style/numehelp.cxx
+++ b/xmloff/source/style/numehelp.cxx
@@ -185,7 +185,7 @@ void XMLNumberFormatAttributesExportHelper::WriteAttributes(SvXMLExport& rXMLExp
}
else
{
- if (::rtl::math::approxEqual( rValue, 0.0 ))
+ if (rValue == 0.0)
{
rXMLExport.AddAttribute(XML_NAMESPACE_OFFICE, XML_BOOLEAN_VALUE, XML_FALSE);
}
@@ -454,7 +454,7 @@ void XMLNumberFormatAttributesExportHelper::WriteAttributes(
}
else
{
- if (::rtl::math::approxEqual( rValue, 0.0 ))
+ if (rValue == 0.0)
{
pExport->AddAttribute(sAttrBooleanValue, XML_FALSE);
}
diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx
index 291b8d21013f..26cea156ca73 100644
--- a/xmloff/source/text/txtflde.cxx
+++ b/xmloff/source/text/txtflde.cxx
@@ -2616,7 +2616,7 @@ void XMLTextFieldExport::ProcessDateTime(enum XMLTokenEnum eName,
if (bIsDuration)
{
// date/time duration handle bOmitDurationIfZero
- if (!bOmitDurationIfZero || !::rtl::math::approxEqual(dValue, 0.0))
+ if (!bOmitDurationIfZero || dValue != 0.0)
{
::sax::Converter::convertDuration(aBuffer, dValue);
}