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

Caolán McNamara caolanm at redhat.com
Thu Mar 26 06:38:09 PDT 2015


 framework/source/layoutmanager/layoutmanager.cxx |    9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 3c22024f41029dd4c1dca6b265d1fd0f14fc2f95
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Mar 26 13:37:10 2015 +0000

    Resolves: tdf#90256 repair invalid docking positions
    
    Change-Id: If144a867dc4be6975c08cd1eea9ebb540975aafc

diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index d4e4eee..94e99ff 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -531,8 +531,15 @@ bool LayoutManager::readWindowStateData( const OUString& aName, UIElement& rElem
                     else if ( aWindowState[n].Name == WINDOWSTATE_PROPERTY_DOCKPOS )
                     {
                         awt::Point aPoint;
-                        if ( aWindowState[n].Value >>= aPoint )
+                        if (aWindowState[n].Value >>= aPoint)
+                        {
+                            //tdf#90256 repair these broken Docking positions
+                            if (aPoint.X < 0)
+                                aPoint.X = SAL_MAX_INT32;
+                            if (aPoint.Y < 0)
+                                aPoint.Y = SAL_MAX_INT32;
                             rElementData.m_aDockedData.m_aPos = aPoint;
+                        }
                     }
                     else if ( aWindowState[n].Name == WINDOWSTATE_PROPERTY_POS )
                     {


More information about the Libreoffice-commits mailing list