[Libreoffice-commits] core.git: Branch 'libreoffice-7-0' - fpicker/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Wed Oct 28 08:37:47 UTC 2020
fpicker/source/office/fileview.cxx | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 2464e2e6894d5e820d8268bc80e3a696521d832f
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Oct 27 14:07:05 2020 +0000
Commit: Michael Stahl <michael.stahl at cib.de>
CommitDate: Wed Oct 28 09:37:14 2020 +0100
Resolves: tdf#137575 fpicker custom sorting setting not restored
Change-Id: Id5fae909a12621f68eb8defcb01b91c304c61df6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104839
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl at cib.de>
diff --git a/fpicker/source/office/fileview.cxx b/fpicker/source/office/fileview.cxx
index 7b5bd1d63c85..5b91dfa2295d 100644
--- a/fpicker/source/office/fileview.cxx
+++ b/fpicker/source/office/fileview.cxx
@@ -1096,8 +1096,8 @@ OUString SvtFileView::GetConfigString() const
void SvtFileView::SetConfigString(const OUString& rCfgStr)
{
sal_Int32 nIdx = 0;
- mpImpl->mnSortColumn = static_cast<sal_uInt16>(rCfgStr.getToken( 0, ';', nIdx ).toInt32());
- mpImpl->mbAscending = static_cast<bool>(static_cast<sal_uInt16>(rCfgStr.getToken( 0, ';', nIdx ).toInt32()));
+ sal_uInt16 nSortColumn = static_cast<sal_uInt16>(rCfgStr.getToken( 0, ';', nIdx ).toInt32());
+ bool bAscending = static_cast<bool>(static_cast<sal_uInt16>(rCfgStr.getToken( 0, ';', nIdx ).toInt32()));
std::vector<int> aWidths(mpImpl->mxView->TypeColumnVisible() ? 4 : 3, -1);
@@ -1118,6 +1118,9 @@ void SvtFileView::SetConfigString(const OUString& rCfgStr)
weld::TreeView* pView = mpImpl->mxView->getWidget();
pView->set_column_fixed_widths(aWidths);
+ if (mpImpl->mnSortColumn != nSortColumn)
+ pView->set_sort_indicator(TRISTATE_INDET, mpImpl->GetSortColumn());
+ mpImpl->Resort_Impl(nSortColumn, bAscending);
}
SvtFileView_Impl::SvtFileView_Impl(SvtFileView* pAntiImpl, weld::Window* pTopLevel,
More information about the Libreoffice-commits
mailing list