summaryrefslogtreecommitdiff
path: root/sfx2
diff options
context:
space:
mode:
authorCarsten Driesner <cd@openoffice.org>2001-08-03 17:00:36 +0000
committerCarsten Driesner <cd@openoffice.org>2001-08-03 17:00:36 +0000
commit05ed69dc4d201ea37e4c0ddefb45bceea243f023 (patch)
tree578e5463a30b33c4bde228efc70490e00bc51144 /sfx2
parentdd6712fa5a60a46823fa3f3b5fda0c1308973e52 (diff)
#87722# support new xml configuration for toolboxes,menus,statusbars,accelerators
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/control/dispatch.cxx26
1 files changed, 24 insertions, 2 deletions
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index 2176cf4175cb..674c3a38ccf0 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: dispatch.cxx,v $
*
- * $Revision: 1.11 $
+ * $Revision: 1.12 $
*
- * last change: $Author: mba $ $Date: 2001-06-21 15:36:57 $
+ * last change: $Author: cd $ $Date: 2001-08-03 18:00:36 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -124,6 +124,7 @@
#include "tbxconf.hxx"
#include "topfrm.hxx"
#include "sfxuno.hxx"
+#include "cfgmgr.hxx"
//==================================================================
DBG_NAME(SfxDispatcherFlush);
@@ -1913,6 +1914,27 @@ sal_uInt32 SfxDispatcher::_Update_Impl( sal_Bool bUIActive, sal_Bool bIsMDIApp,
rBar.aResId = ResId( 0,0 );
}
+ if ( bUIActive || bIsActive )
+ {
+ SfxConfigManager* pMgr = pImp->pFrame->GetObjectShell()->GetConfigManager();
+ SfxInterface* pIFace = pImp->pFrame->GetObjectShell()->GetInterface();
+ USHORT nMask = SFX_VISIBILITY_CLIENT | SFX_VISIBILITY_STANDARD;
+ if ( !pMgr )
+ {
+ pMgr = SFX_APP()->GetConfigManager_Impl();
+ pIFace = SFX_APP()->GetInterface();
+ nMask = SFX_VISIBILITY_SERVER | SFX_VISIBILITY_STANDARD;
+
+ }
+
+ for ( USHORT n=0; n<4; n++ )
+ {
+ USHORT nType = n + RID_SFX_TOOLBOX_START + 10;
+ if ( pMgr->HasConfigItem( nType ) )
+ pWorkWin->SetObjectBar_Impl( (SFX_OBJECTBAR_USERDEF1 + n) | nMask, nType, pIFace, (const String*) NULL );
+ }
+ }
+
for ( nNo=0; pIFace && nNo<pIFace->GetChildWindowCount(); nNo++ )
{
sal_uInt32 nId = pIFace->GetChildWindowId(nNo);