diff options
author | Oliver Bolte <obo@openoffice.org> | 2004-07-06 16:03:34 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2004-07-06 16:03:34 +0000 |
commit | 3f03cb71c31da316686c7fa67b16888da27376ab (patch) | |
tree | 3bc8aaa0f8a40eddd668ec9536bdcf216d510ecb /framework | |
parent | a8db12ec6a9fae4b2ce1ce0b1558f93a68833a0c (diff) |
INTEGRATION: CWS docking1 (1.2.4); FILE MERGED
2004/04/21 07:08:54 cd 1.2.4.1: #i24937# Added new factory definition schema to support an addon toolbar factory
Diffstat (limited to 'framework')
-rw-r--r-- | framework/source/uifactory/uielementfactorymanager.cxx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/framework/source/uifactory/uielementfactorymanager.cxx b/framework/source/uifactory/uielementfactorymanager.cxx index 52f493b96970..50133e4dc16f 100644 --- a/framework/source/uifactory/uielementfactorymanager.cxx +++ b/framework/source/uifactory/uielementfactorymanager.cxx @@ -2,9 +2,9 @@ * * $RCSfile: uielementfactorymanager.cxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: kz $ $Date: 2004-02-25 17:53:25 $ + * last change: $Author: obo $ $Date: 2004-07-06 17:03:34 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -273,6 +273,16 @@ rtl::OUString ConfigurationAccess_UIElementFactoryManager::getFactorySpecifierFr return pIter->second; else { + // Support factories which uses a defined prefix before the ui name. + sal_Int32 nIndex = rName.indexOf( '_' ); + if ( nIndex > 0 ) + { + rtl::OUString aName = rName.copy( 0, nIndex+1 ); + pIter = m_aUIElementFactoryManagerMap.find( getHashKeyFromStrings( rType, aName, rtl::OUString() )); + if ( pIter != m_aUIElementFactoryManagerMap.end() ) + return pIter->second; + } + pIter = m_aUIElementFactoryManagerMap.find( getHashKeyFromStrings( rType, rtl::OUString(), rtl::OUString() )); if ( pIter != m_aUIElementFactoryManagerMap.end() ) return pIter->second; |