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

Yousuf Philips philipz85 at hotmail.com
Sat Sep 3 20:06:47 UTC 2016


 svx/source/tbxctrls/SvxPresetListBox.cxx |    9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

New commits:
commit ca504cd4ca381e5d24a82e588dac51c344c6f946
Author: Yousuf Philips <philipz85 at hotmail.com>
Date:   Tue Aug 30 15:39:51 2016 +0400

    tdf#94551 Preset list: 3 entries per row and always show scrollbar
    
    Change-Id: I748b92d01031120e750f306549c7d46ed29a313a
    Reviewed-on: https://gerrit.libreoffice.org/28492
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Maxim Monastirsky <momonasmon at gmail.com>

diff --git a/svx/source/tbxctrls/SvxPresetListBox.cxx b/svx/source/tbxctrls/SvxPresetListBox.cxx
index 0786d9d..5527812 100644
--- a/svx/source/tbxctrls/SvxPresetListBox.cxx
+++ b/svx/source/tbxctrls/SvxPresetListBox.cxx
@@ -30,9 +30,9 @@
 
 SvxPresetListBox::SvxPresetListBox(vcl::Window* pParent, WinBits nWinStyle)
     : ValueSet(pParent, nWinStyle),
-      nColCount(2),
+      nColCount(3),
       nRowCount(5),
-      aIconSize( Size(80,60) )
+      aIconSize( Size(60,64) )
 {
     SetEdgeBlending(true);
     SetExtraSpacing(4);
@@ -53,10 +53,7 @@ void SvxPresetListBox::Resize()
 {
     DrawLayout();
     WinBits aWinBits(GetStyle());
-    if( nColCount*nRowCount <  static_cast<sal_uInt16>(GetItemCount()) )
-        aWinBits |= WB_VSCROLL;
-    else
-        aWinBits &= ~WB_VSCROLL;
+    aWinBits |= WB_VSCROLL;
     SetStyle(aWinBits);
     ValueSet::Resize();
 }


More information about the Libreoffice-commits mailing list