Kaydet (Commit) 058cfa72 authored tarafından Thorsten Behrens's avatar Thorsten Behrens

Fix fdo#71423 - crash while editing Impress tables.

Band-aid fix for this nasty crasher, seems sometimes the
family item is not found.

Change-Id: I7f78d59cbf2c9595ad512fa7a78370629924cd06
üst 23648e82
...@@ -1191,6 +1191,8 @@ void SfxCommonTemplateDialog_Impl::FillTreeBox() ...@@ -1191,6 +1191,8 @@ void SfxCommonTemplateDialog_Impl::FillTreeBox()
if(pStyleSheetPool && nActFamily != 0xffff) if(pStyleSheetPool && nActFamily != 0xffff)
{ {
const SfxStyleFamilyItem *pItem = GetFamilyItem_Impl(); const SfxStyleFamilyItem *pItem = GetFamilyItem_Impl();
if(!pItem)
return;
pStyleSheetPool->SetSearchMask(pItem->GetFamily(), SFXSTYLEBIT_ALL_VISIBLE); pStyleSheetPool->SetSearchMask(pItem->GetFamily(), SFXSTYLEBIT_ALL_VISIBLE);
StyleTreeArr_Impl aArr; StyleTreeArr_Impl aArr;
SfxStyleSheetBase *pStyle = pStyleSheetPool->First(); SfxStyleSheetBase *pStyle = pStyleSheetPool->First();
...@@ -1533,7 +1535,7 @@ void SfxCommonTemplateDialog_Impl::Update_Impl() ...@@ -1533,7 +1535,7 @@ void SfxCommonTemplateDialog_Impl::Update_Impl()
// other filters for automatic // other filters for automatic
CheckItem( nActFamily, true ); CheckItem( nActFamily, true );
const SfxStyleFamilyItem *pStyleItem = GetFamilyItem_Impl(); const SfxStyleFamilyItem *pStyleItem = GetFamilyItem_Impl();
if ( 0 == pStyleItem->GetFilterList()[ nActFilter ]->nFlags if ( pStyleItem && 0 == pStyleItem->GetFilterList()[ nActFilter ]->nFlags
&& nAppFilter != pItem->GetValue()) && nAppFilter != pItem->GetValue())
{ {
nAppFilter = pItem->GetValue(); nAppFilter = pItem->GetValue();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment