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

Jan Holesovsky kendy at collabora.com
Tue Dec 16 23:36:11 PST 2014


 vcl/source/window/layout.cxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 4e1e9eb2fb08fcddf076051501c875ce0766964b
Author: Jan Holesovsky <kendy at collabora.com>
Date:   Wed Dec 17 08:34:52 2014 +0100

    vcl: Sidebar corner case.

diff --git a/vcl/source/window/layout.cxx b/vcl/source/window/layout.cxx
index c13e6b4..be1e060 100644
--- a/vcl/source/window/layout.cxx
+++ b/vcl/source/window/layout.cxx
@@ -755,11 +755,11 @@ VclGrid::array_type VclGrid::assembleGrid() const
     for (vcl::Window* pChild = GetWindow(WINDOW_FIRSTCHILD); pChild;
         pChild = pChild->GetWindow(WINDOW_NEXT))
     {
-        sal_Int32 nLeftAttach = pChild->get_grid_left_attach();
+        sal_Int32 nLeftAttach = std::max(pChild->get_grid_left_attach(), 0);
         sal_Int32 nWidth = pChild->get_grid_width();
         sal_Int32 nMaxXPos = nLeftAttach+nWidth-1;
 
-        sal_Int32 nTopAttach = pChild->get_grid_top_attach();
+        sal_Int32 nTopAttach = std::max(pChild->get_grid_top_attach(), 0);
         sal_Int32 nHeight = pChild->get_grid_height();
         sal_Int32 nMaxYPos = nTopAttach+nHeight-1;
 


More information about the Libreoffice-commits mailing list