diff options
author | Caolán McNamara <caolanm@redhat.com> | 2019-05-10 16:21:46 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2019-05-10 22:26:30 +0200 |
commit | 8da6a8fcf1a71588a22bf4afae8d5e54b7b0bcad (patch) | |
tree | fde75292255b89a513d4fc08b33d6d0f4fa2b1c0 /sw | |
parent | d422a9d0cb914260192fbc68305db088af022204 (diff) |
fix assert for expand_row while frozen
Change-Id: I78578cd1578317a16d2eb62e23ddcc01bc39347a
Reviewed-on: https://gerrit.libreoffice.org/72130
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/ui/fldui/flddinf.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sw/source/ui/fldui/flddinf.cxx b/sw/source/ui/fldui/flddinf.cxx index 6ec3db4e8cf8..0603774eb127 100644 --- a/sw/source/ui/fldui/flddinf.cxx +++ b/sw/source/ui/fldui/flddinf.cxx @@ -126,6 +126,7 @@ void SwFieldDokInfPage::Reset(const SfxItemSet* ) std::vector<OUString> aLst; GetFieldMgr().GetSubTypes(TYP_DOCINFOFLD, aLst); std::unique_ptr<weld::TreeIter> xEntry(m_xTypeTLB->make_iterator()); + std::unique_ptr<weld::TreeIter> xExpandEntry; for(size_t i = 0; i < aLst.size(); ++i) { if (!IsFieldEdit() || nSubType == i) @@ -155,7 +156,7 @@ void SwFieldDokInfPage::Reset(const SfxItemSet* ) if (m_sOldCustomFieldName == sEntry) { m_xSelEntry = m_xTypeTLB->make_iterator(xEntry.get()); - m_xTypeTLB->expand_row(*xInfo); + xExpandEntry = m_xTypeTLB->make_iterator(xInfo.get()); } } } @@ -176,6 +177,9 @@ void SwFieldDokInfPage::Reset(const SfxItemSet* ) m_xTypeTLB->thaw(); + if (xExpandEntry) + m_xTypeTLB->expand_row(*xExpandEntry); + // select old Pos if (m_xSelEntry) { |