summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorRishabh Kumar <kris.kr296@gmail.com>2016-07-21 21:57:26 +0530
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2016-07-21 19:46:22 +0000
commit6f2b129a8e327f4226314944bc86eca78e5b1797 (patch)
tree6e7fc0a0fb5aaebe9085232ab82219ecde76995b /cui
parent9a91d492e4d77d41f21bde9ee4aa2d57d6be693f (diff)
Minor UI changes for SvxPresetListBox
1. Reduced item icon size. 2. Add slider depending on the number of entries. Change-Id: I1fad15861438952664c26666afe89fffa08051f6 Reviewed-on: https://gerrit.libreoffice.org/27389 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'cui')
-rw-r--r--cui/source/tabpages/tpgradnt.cxx2
-rw-r--r--cui/source/tabpages/tphatch.cxx2
-rw-r--r--cui/source/tabpages/tppattern.cxx2
3 files changed, 6 insertions, 0 deletions
diff --git a/cui/source/tabpages/tpgradnt.cxx b/cui/source/tabpages/tpgradnt.cxx
index 0f3d0f5b0d47..7e9eba6c2eeb 100644
--- a/cui/source/tabpages/tpgradnt.cxx
+++ b/cui/source/tabpages/tpgradnt.cxx
@@ -520,6 +520,7 @@ IMPL_LINK_NOARG_TYPED(SvxGradientTabPage, ClickAddHdl_Impl, Button*, void)
Bitmap aBitmap = m_pGradientList->GetBitmapForPreview( nCount, m_pGradientLB->GetIconSize() );
m_pGradientLB->InsertItem( nId + 1, Image(aBitmap), aName );
m_pGradientLB->SelectItem( nId + 1 );
+ m_pGradientLB->Resize();
*m_pnGradientListState |= ChangeType::MODIFIED;
@@ -579,6 +580,7 @@ IMPL_LINK_NOARG_TYPED(SvxGradientTabPage, ClickDeleteHdl_Impl, SvxPresetListBox*
m_pGradientLB->RemoveItem( nId );
nId = m_pGradientLB->GetItemId( 0 );
m_pGradientLB->SelectItem( nId );
+ m_pGradientLB->Resize();
m_pCtlPreview->Invalidate();
diff --git a/cui/source/tabpages/tphatch.cxx b/cui/source/tabpages/tphatch.cxx
index 941fe259d673..33eb0d30e147 100644
--- a/cui/source/tabpages/tphatch.cxx
+++ b/cui/source/tabpages/tphatch.cxx
@@ -584,6 +584,7 @@ IMPL_LINK_NOARG_TYPED(SvxHatchTabPage, ClickAddHdl_Impl, Button*, void)
// Insert the new entry at the next ID
m_pHatchLB->InsertItem( nId + 1, Image(aBitmap), aName );
m_pHatchLB->SelectItem( nId + 1 );
+ m_pHatchLB->Resize();
*m_pnHatchingListState |= ChangeType::MODIFIED;
@@ -640,6 +641,7 @@ IMPL_LINK_NOARG_TYPED(SvxHatchTabPage, ClickDeleteHdl_Impl, SvxPresetListBox*, v
m_pHatchLB->RemoveItem( nId );
nId = m_pHatchLB->GetItemId(0);
m_pHatchLB->SelectItem( nId );
+ m_pHatchLB->Resize();
m_pCtlPreview->Invalidate();
diff --git a/cui/source/tabpages/tppattern.cxx b/cui/source/tabpages/tppattern.cxx
index 48560ce6cd69..4b2570b18273 100644
--- a/cui/source/tabpages/tppattern.cxx
+++ b/cui/source/tabpages/tppattern.cxx
@@ -552,6 +552,7 @@ IMPL_LINK_NOARG_TYPED(SvxPatternTabPage, ClickAddHdl_Impl, Button*, void)
Bitmap aBitmap = m_pPatternList->GetBitmapForPreview( nCount, m_pPatternLB->GetIconSize() );
m_pPatternLB->InsertItem( nId + 1, Image(aBitmap), aName );
m_pPatternLB->SelectItem( nId + 1 );
+ m_pPatternLB->Resize();
*m_pnPatternListState |= ChangeType::MODIFIED;
@@ -672,6 +673,7 @@ IMPL_LINK_NOARG_TYPED(SvxPatternTabPage, ClickDeleteHdl_Impl, SvxPresetListBox*,
m_pPatternLB->RemoveItem( nId );
nId = m_pPatternLB->GetItemId(0);
m_pPatternLB->SelectItem( nId );
+ m_pPatternLB->Resize();
m_pCtlPreview->Invalidate();
m_pCtlPixel->Invalidate();