diff options
-rw-r--r-- | framework/source/uifactory/uielementfactorymanager.cxx | 16 | ||||
-rwxr-xr-x | solenv/bin/native-code.py | 1 |
2 files changed, 12 insertions, 5 deletions
diff --git a/framework/source/uifactory/uielementfactorymanager.cxx b/framework/source/uifactory/uielementfactorymanager.cxx index 68cf917d9d5a..2282b0626895 100644 --- a/framework/source/uifactory/uielementfactorymanager.cxx +++ b/framework/source/uifactory/uielementfactorymanager.cxx @@ -28,6 +28,7 @@ #include <com/sun/star/container/XContainer.hpp> #include <com/sun/star/container/XContainerListener.hpp> #include <com/sun/star/lang/XServiceInfo.hpp> +#include <com/sun/star/loader/CannotActivateFactoryException.hpp> #include <com/sun/star/frame/ModuleManager.hpp> #include <com/sun/star/frame/XFrame.hpp> #include <com/sun/star/frame/XModuleManager2.hpp> @@ -503,10 +504,17 @@ throw ( RuntimeException ) aServiceSpecifier = m_pConfigAccess->getFactorySpecifierFromTypeNameModule( aType, aName, aModuleId ); } // SAFE - if ( !aServiceSpecifier.isEmpty() ) - return Reference< XUIElementFactory >( m_xContext->getServiceManager()->createInstanceWithContext(aServiceSpecifier, m_xContext), UNO_QUERY ); - else - return Reference< XUIElementFactory >(); + if ( !aServiceSpecifier.isEmpty() ) try + { + return Reference< XUIElementFactory >(m_xContext->getServiceManager()-> + createInstanceWithContext(aServiceSpecifier, m_xContext), UNO_QUERY); + } + catch ( const css::loader::CannotActivateFactoryException& ) + { + SAL_WARN("fwk.uielement", aServiceSpecifier << + " not available. This should happen only on mobile platforms."); + } + return Reference< XUIElementFactory >(); } void SAL_CALL UIElementFactoryManager::registerFactory( const OUString& aType, const OUString& aName, const OUString& aModuleId, const OUString& aFactoryImplementationName ) diff --git a/solenv/bin/native-code.py b/solenv/bin/native-code.py index cf57fc179ea9..3883a8dc4e43 100755 --- a/solenv/bin/native-code.py +++ b/solenv/bin/native-code.py @@ -48,7 +48,6 @@ core_factory_list = [ core_constructor_list = [ # framework/util/fwk.component - "com_sun_star_comp_framework_AddonsToolBarFactory_get_implementation", "com_sun_star_comp_framework_AutoRecovery_get_implementation", "com_sun_star_comp_framework_Frame_get_implementation", "com_sun_star_comp_framework_JobExecutor_get_implementation", |