From 95552ecffeef703eac55e1095c27962795b55b82 Mon Sep 17 00:00:00 2001 From: Niklas Nebel Date: Thu, 15 Jul 2010 14:11:48 +0200 Subject: calc56: #i113159# check if GetTextEditOutlinerView is null in thesaurus state method --- sd/source/ui/view/drtxtob.cxx | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/sd/source/ui/view/drtxtob.cxx b/sd/source/ui/view/drtxtob.cxx index 8b88be3682e3..0b99201c611a 100755 --- a/sd/source/ui/view/drtxtob.cxx +++ b/sd/source/ui/view/drtxtob.cxx @@ -384,10 +384,15 @@ void TextObjectBar::GetAttrState( SfxItemSet& rSet ) case SID_THES: { - EditView & rEditView = mpView->GetTextEditOutlinerView()->GetEditView();; + OutlinerView* pOLV = mpView->GetTextEditOutlinerView(); String aStatusVal; LanguageType nLang = LANGUAGE_NONE; - bool bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, rEditView ); + bool bIsLookUpWord = false; + if ( pOLV ) + { + EditView& rEditView = pOLV->GetEditView(); + bIsLookUpWord = GetStatusValueForThesaurusFromContext( aStatusVal, nLang, rEditView ); + } rSet.Put( SfxStringItem( SID_THES, aStatusVal ) ); // disable "Thesaurus" context menu entry if there is nothing to look up -- cgit