[Libreoffice-commits] core.git: svx/source

Stephan Bergmann sbergman at redhat.com
Fri Aug 22 08:18:27 PDT 2014


 svx/source/customshapes/EnhancedCustomShape2d.cxx |    2 +-
 svx/source/svdraw/svdobj.cxx                      |    6 ++++--
 2 files changed, 5 insertions(+), 3 deletions(-)

New commits:
commit 720ee909292db389606511d6fac75ad03d72d695
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Fri Aug 22 17:17:52 2014 +0200

    Point and Rectangle coordinates are long, not sal_Int32
    
    Change-Id: I0f97d12f55e506af699976bf81f4dcf956195aab

diff --git a/svx/source/customshapes/EnhancedCustomShape2d.cxx b/svx/source/customshapes/EnhancedCustomShape2d.cxx
index 175b2a0..df29afc 100644
--- a/svx/source/customshapes/EnhancedCustomShape2d.cxx
+++ b/svx/source/customshapes/EnhancedCustomShape2d.cxx
@@ -963,7 +963,7 @@ Point EnhancedCustomShape2d::GetPoint( const com::sun::star::drawing::EnhancedCu
                 if ( nFlags & DFF_CUSTOMSHAPE_FLIP_H )
                     fVal = aLogicRect.GetWidth() - fVal;
             }
-            aRetValue.X() = (sal_Int32)fVal;
+            aRetValue.X() = static_cast<long>(fVal);
         }
     }
     while ( ++nPass < 2 );
diff --git a/svx/source/svdraw/svdobj.cxx b/svx/source/svdraw/svdobj.cxx
index 8f02887..dc2d8d8 100644
--- a/svx/source/svdraw/svdobj.cxx
+++ b/svx/source/svdraw/svdobj.cxx
@@ -972,8 +972,10 @@ void SdrObject::RecalcBoundRect()
             if(!aRange.isEmpty())
             {
                 aOutRect = Rectangle(
-                        (sal_Int32)floor(aRange.getMinX()), (sal_Int32)floor(aRange.getMinY()),
-                        (sal_Int32)ceil(aRange.getMaxX()), (sal_Int32)ceil(aRange.getMaxY()));
+                    static_cast<long>(floor(aRange.getMinX())),
+                    static_cast<long>(floor(aRange.getMinY())),
+                    static_cast<long>(ceil(aRange.getMaxX())),
+                    static_cast<long>(ceil(aRange.getMaxY())));
                 aOutRect -= GetGridOffset(); // don't include grid offset
                 return;
             }


More information about the Libreoffice-commits mailing list