sc/source/ui/dbgui/tpsort.cxx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-)
New commits: commit 15e0ef908c9e54527276500cf7a537055c374850 Author: Albert Thuswaldner <albert.thuswald...@gmail.com> Date: Sat Apr 6 21:43:48 2013 +0200 fdo#51828 - UI: Sort: can use more than 3 criteria once only Change-Id: I7480e8d606e1eafde45635e36dfafa4232f529cb Reviewed-on: https://gerrit.libreoffice.org/3217 Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/sc/source/ui/dbgui/tpsort.cxx b/sc/source/ui/dbgui/tpsort.cxx index 4c56058..6731e71 100644 --- a/sc/source/ui/dbgui/tpsort.cxx +++ b/sc/source/ui/dbgui/tpsort.cxx @@ -168,9 +168,19 @@ void ScTabPageSortFields::Reset( const SfxItemSet& /* rArgSet */ ) // ListBox selection: if ( aSortData.maKeyState[0].bDoSort ) { + // Make sure that the all sort keys are reset + for ( sal_uInt16 i=nSortKeyCount; i<aSortData.maKeyState.size(); i++ ) + { + maSortKeyCtrl.AddSortKey(i+1); + maSortKeyItems[i].m_pLbSort->SetSelectHdl( LINK( this, + ScTabPageSortFields, SelectHdl ) ); + } + nSortKeyCount = aSortData.maKeyState.size(); + FillFieldLists(0); + for ( sal_uInt16 i=0; i<nSortKeyCount; i++ ) { - if ( i < aSortData.maKeyState.size() && aSortData.maKeyState[i].bDoSort ) + if (aSortData.maKeyState[i].bDoSort ) { maSortKeyItems[i].m_pLbSort->SelectEntryPos( GetFieldSelPos( aSortData.maKeyState[i].nField ) ); @@ -193,7 +203,6 @@ void ScTabPageSortFields::Reset( const SfxItemSet& /* rArgSet */ ) maSortKeyItems[i].DisableField(); else maSortKeyItems[i].EnableField(); - } else {
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits