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

Caolán McNamara caolanm at redhat.com
Thu Sep 15 07:56:18 UTC 2016


 svx/source/unodraw/unoshap4.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 7f0a219c9ad38ae33b51ff69d545f69659691c1e
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Sep 14 13:37:22 2016 +0100

    Unmodified default SdrOle2Obj size is 101x101
    
    svx/source/unodraw/unoshape.cxx
    
    sets a css::awt::Size maSize to 100, 100
    
    svx/source/unodraw/unopage.cxx
    
    increases that by 1, 1
    
    awt::Size aSize = xShape->getSize();
    aSize.Width += 1;
    aSize.Height += 1;
    
    to call SdrObjFactory::MakeNewObject with 101, 101
    so default size is 101x101 (getWidth() vs GetWidth() confusion ?)
    
    Change-Id: I4d4375dff64d7b8e236d1a24322e749e04ee530f
    Reviewed-on: https://gerrit.libreoffice.org/28895
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/svx/source/unodraw/unoshap4.cxx b/svx/source/unodraw/unoshap4.cxx
index ee87c46..97fa794 100644
--- a/svx/source/unodraw/unoshap4.cxx
+++ b/svx/source/unodraw/unoshap4.cxx
@@ -410,7 +410,7 @@ bool SvxOle2Shape::createObject( const SvGlobalName &aClassName )
     if( xObj.is() )
     {
         Rectangle aRect = pOle2Obj->GetLogicRect();
-        if ( aRect.GetWidth() == 100 && aRect.GetHeight() == 100 )
+        if ( aRect.GetWidth() == 101 && aRect.GetHeight() == 101 )
         {
             // TODO/LATER: is it possible that this method is used to create an iconified object?
             // default size
@@ -478,7 +478,7 @@ void SvxOle2Shape::createLink( const OUString& aLinkURL )
     if( xObj.is() )
     {
         Rectangle aRect = pOle2Obj->GetLogicRect();
-        if ( aRect.GetWidth() == 100 && aRect.GetHeight() == 100 )
+        if ( aRect.GetWidth() == 101 && aRect.GetHeight() == 101 )
         {
             // default size
             try


More information about the Libreoffice-commits mailing list