summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/cellsh.cxx
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2010-04-12 17:59:48 +0200
committerJens-Heiner Rechtien <hr@openoffice.org>2010-04-12 17:59:48 +0200
commit4cb5221199052f80055b978063cb73f05f8563c0 (patch)
tree03948f721c232047193b43f59e758204a73dba79 /sc/source/ui/view/cellsh.cxx
parent6a30f2a3025a9db27d1230d9498570964cd74e3f (diff)
parent08b211692c10f69c1eba69b7ee290744d96c5cbb (diff)
CWS-TOOLING: integrate CWS dr74
Diffstat (limited to 'sc/source/ui/view/cellsh.cxx')
-rw-r--r--sc/source/ui/view/cellsh.cxx24
1 files changed, 24 insertions, 0 deletions
diff --git a/sc/source/ui/view/cellsh.cxx b/sc/source/ui/view/cellsh.cxx
index 6d3f10e2ec5e..a461c54f255e 100644
--- a/sc/source/ui/view/cellsh.cxx
+++ b/sc/source/ui/view/cellsh.cxx
@@ -42,6 +42,7 @@
#include <svx/hlnkitem.hxx>
#include <sfx2/app.hxx>
#include <sfx2/bindings.hxx>
+#include <sfx2/childwin.hxx>
#include <sfx2/objface.hxx>
#include <sfx2/request.hxx>
#include <sfx2/viewfrm.hxx>
@@ -970,6 +971,29 @@ void ScCellShell::GetState(SfxItemSet &rSet)
}
break;
+ case SID_SPELL_DIALOG:
+ {
+ if ( pDoc && pData && pDoc->IsTabProtected( pData->GetTabNo() ) )
+ {
+ bool bVisible = false;
+ SfxViewFrame* pViewFrame = ( pTabViewShell ? pTabViewShell->GetViewFrame() : NULL );
+ if ( pViewFrame && pViewFrame->HasChildWindow( nWhich ) )
+ {
+ SfxChildWindow* pChild = pViewFrame->GetChildWindow( nWhich );
+ Window* pWin = ( pChild ? pChild->GetWindow() : NULL );
+ if ( pWin && pWin->IsVisible() )
+ {
+ bVisible = true;
+ }
+ }
+ if ( !bVisible )
+ {
+ rSet.DisableItem( nWhich );
+ }
+ }
+ }
+ break;
+
} // switch ( nWitch )
nWhich = aIter.NextWhich();
} // while ( nWitch )