30 lines
1.5 KiB
Diff
30 lines
1.5 KiB
Diff
|
From 494aa9ee5d01699c0dcbc912091de30a314c09fc Mon Sep 17 00:00:00 2001
|
||
|
From: =?UTF-8?q?Mat=C3=BA=C5=A1=20Kukan?= <matus.kukan@gmail.com>
|
||
|
Date: Fri, 18 Sep 2015 12:57:39 +0200
|
||
|
Subject: Workaround unit test failure by comparing as long
|
||
|
|
||
|
On 32bit system, for some reason casting to double gives wrong results.
|
||
|
Failing unit test was testTdf87924 in CppunitTest_sw_ooxmlimport.
|
||
|
|
||
|
Change-Id: If93e5288a381e50f30d035d56131b1d9235ac658
|
||
|
Reviewed-on: https://gerrit.libreoffice.org/18684
|
||
|
Tested-by: Jenkins <ci@libreoffice.org>
|
||
|
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
|
||
|
|
||
|
diff --git a/oox/source/shape/WpsContext.cxx b/oox/source/shape/WpsContext.cxx
|
||
|
index 657071b..0cf558c 100644
|
||
|
--- a/oox/source/shape/WpsContext.cxx
|
||
|
+++ b/oox/source/shape/WpsContext.cxx
|
||
|
@@ -100,7 +100,7 @@ oox::core::ContextHandlerRef WpsContext::onCreateContext(sal_Int32 nElementToken
|
||
|
|
||
|
// If the text is not rotated the way the shape wants it already, set the angle.
|
||
|
const sal_Int32 nRotation = -270;
|
||
|
- if (basegfx::rad2deg(fRotate) != static_cast<double>(NormAngle360(nRotation * 100)) / 100)
|
||
|
+ if (static_cast<long>(basegfx::rad2deg(fRotate)) != NormAngle360(nRotation * 100) / 100)
|
||
|
{
|
||
|
comphelper::SequenceAsHashMap aCustomShapeGeometry(xPropertySet->getPropertyValue("CustomShapeGeometry"));
|
||
|
aCustomShapeGeometry["TextPreRotateAngle"] = uno::makeAny(nRotation);
|
||
|
--
|
||
|
cgit v0.10.2
|
||
|
|