diff options
author | Oliver Bolte <obo@openoffice.org> | 2005-04-18 13:35:29 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2005-04-18 13:35:29 +0000 |
commit | d6d77468d4016237633fa07fd08e6e3ff03addd0 (patch) | |
tree | 5903e5a6ab001cde48e3398891934f4ed2b7a37d | |
parent | 6b7d7809c97424ef08f1980f0f03b3caaaa2a0ed (diff) |
INTEGRATION: CWS olefix (1.16.8); FILE MERGED
2005/04/07 06:42:14 cd 1.16.8.2: #i46836# Generic toolbar manager must be always created. They also support the dynamic visibility feature with status updates
2005/04/06 14:36:53 cd 1.16.8.1: #i48636# Don't create load URL and generic controller their toolbar element is not visible
-rw-r--r-- | framework/source/uielement/toolbarmanager.cxx | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/framework/source/uielement/toolbarmanager.cxx b/framework/source/uielement/toolbarmanager.cxx index 7cd9f34119cb..1479c1e54cb2 100644 --- a/framework/source/uielement/toolbarmanager.cxx +++ b/framework/source/uielement/toolbarmanager.cxx @@ -2,9 +2,9 @@ * * $RCSfile: toolbarmanager.cxx,v $ * - * $Revision: 1.16 $ + * $Revision: 1.17 $ * - * last change: $Author: kz $ $Date: 2005-03-21 13:28:20 $ + * last change: $Author: obo $ $Date: 2005-04-18 14:35:29 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -975,8 +975,10 @@ void ToolBarManager::CreateControllers( const ControllerParamsVector& rControlle if ( nId == 0 ) continue; + rtl::OUString aLoadURL( RTL_CONSTASCII_USTRINGPARAM( ".uno:OpenUrl" )); rtl::OUString aCommandURL( m_pToolBar->GetItemCommand( nId )); sal_Bool bInit( sal_True ); + sal_Bool bCreate( sal_True ); Reference< XStatusListener > xController; svt::ToolboxController* pController( 0 ); @@ -1018,7 +1020,10 @@ void ToolBarManager::CreateControllers( const ControllerParamsVector& rControlle } } - if ( !xController.is() && m_pToolBar ) + if (( aCommandURL == aLoadURL ) && ( !m_pToolBar->IsItemVisible(nId))) + bCreate = sal_False; + + if ( !xController.is() && m_pToolBar && bCreate ) { pController = CreateToolBoxController( m_xFrame, m_pToolBar, nId, aCommandURL ); if ( !pController ) |