diff options
author | Eike Rathke <erack@redhat.com> | 2014-03-01 03:13:28 +0100 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2014-03-05 07:31:19 -0600 |
commit | 68ec95b3f80408ae50897b043eed69a07d084df9 (patch) | |
tree | 5d32076e843fae44f28e3c8d9dbbacf7648fecbc /svx/source/tbxctrls/fillctrl.cxx | |
parent | c3403ac888c2e62edaf8befe7982f5f8cc95c16f (diff) |
made ListBox handle more than 64k elements, fdo#61520 related
ListBox and related now handle up to sal_Int32 elements correctly.
sal_Int32 instead of sal_Size or size_t because of UNO and a11y API.
Also disentangled some of the mess of SvTreeList and other containers
regarding sal_uInt16, sal_uLong, long, size_t, ... type mixtures.
Change-Id: Idb6e0ae689dc5bc2cf980721972b57b0261e688a
Reviewed-on: https://gerrit.libreoffice.org/8460
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'svx/source/tbxctrls/fillctrl.cxx')
-rw-r--r-- | svx/source/tbxctrls/fillctrl.cxx | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/svx/source/tbxctrls/fillctrl.cxx b/svx/source/tbxctrls/fillctrl.cxx index 44ed0d6ba93b..919fe820f6d7 100644 --- a/svx/source/tbxctrls/fillctrl.cxx +++ b/svx/source/tbxctrls/fillctrl.cxx @@ -169,7 +169,7 @@ void SvxFillToolBoxControl::StateChanged( if(eLastXFS != eXFS) { bUpdate = sal_True; - pFillTypeLB->SelectEntryPos( sal::static_int_cast< sal_uInt16 >( eXFS ) ); + pFillTypeLB->SelectEntryPos( eXFS ); } pFillAttrLB->Enable(); @@ -253,7 +253,7 @@ void SvxFillToolBoxControl::Update( const SfxPoolItem* pState ) LISTBOX_ENTRY_NOTFOUND || pFillAttrLB->GetSelectEntryColor() != aColor ) { - sal_uInt16 nCount = pFillAttrLB->GetEntryCount(); + sal_Int32 nCount = pFillAttrLB->GetEntryCount(); OUString aTmpStr; if( nCount > 0 ) { @@ -268,7 +268,7 @@ void SvxFillToolBoxControl::Update( const SfxPoolItem* pState ) aTmpStr = TMP_STR_BEGIN + aString + TMP_STR_END; //pFillAttrLB->SetUpdateMode( sal_False ); - sal_uInt16 nPos = pFillAttrLB->InsertEntry( aColor, aTmpStr ); + sal_Int32 nPos = pFillAttrLB->InsertEntry( aColor, aTmpStr ); //pFillAttrLB->SetUpdateMode( sal_True ); pFillAttrLB->SelectEntryPos( nPos ); } @@ -287,7 +287,7 @@ void SvxFillToolBoxControl::Update( const SfxPoolItem* pState ) // Check if the entry is not in the list if( pFillAttrLB->GetSelectEntry() != aString ) { - sal_uInt16 nCount = pFillAttrLB->GetEntryCount(); + sal_Int32 nCount = pFillAttrLB->GetEntryCount(); OUString aTmpStr; if( nCount > 0 ) { @@ -332,7 +332,7 @@ void SvxFillToolBoxControl::Update( const SfxPoolItem* pState ) // Check if the entry is not in the list if( pFillAttrLB->GetSelectEntry() != aString ) { - sal_uInt16 nCount = pFillAttrLB->GetEntryCount(); + sal_Int32 nCount = pFillAttrLB->GetEntryCount(); OUString aTmpStr; if( nCount > 0 ) { @@ -384,7 +384,7 @@ void SvxFillToolBoxControl::Update( const SfxPoolItem* pState ) // Check if the entry is not in the list if( pFillAttrLB->GetSelectEntry() != aString ) { - sal_uInt16 nCount = pFillAttrLB->GetEntryCount(); + sal_Int32 nCount = pFillAttrLB->GetEntryCount(); OUString aTmpStr; if( nCount > 0 ) { @@ -689,7 +689,7 @@ IMPL_LINK( FillControl, SelectFillAttrHdl, ListBox *, pBox ) break; case XFILL_GRADIENT: { - sal_uInt16 nPos = pLbFillAttr->GetSelectEntryPos(); + sal_Int32 nPos = pLbFillAttr->GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND && pSh && pSh->GetItem( SID_GRADIENT_LIST ) ) { @@ -713,7 +713,7 @@ IMPL_LINK( FillControl, SelectFillAttrHdl, ListBox *, pBox ) case XFILL_HATCH: { - sal_uInt16 nPos = pLbFillAttr->GetSelectEntryPos(); + sal_Int32 nPos = pLbFillAttr->GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND && pSh && pSh->GetItem( SID_HATCH_LIST ) ) { @@ -736,7 +736,7 @@ IMPL_LINK( FillControl, SelectFillAttrHdl, ListBox *, pBox ) case XFILL_BITMAP: { - sal_uInt16 nPos = pLbFillAttr->GetSelectEntryPos(); + sal_Int32 nPos = pLbFillAttr->GetSelectEntryPos(); if ( nPos != LISTBOX_ENTRY_NOTFOUND && pSh && pSh->GetItem( SID_BITMAP_LIST ) ) { |