From 720759ad342000f2729a6c983523af931f01dbef Mon Sep 17 00:00:00 2001 From: Michael Meeks Date: Mon, 22 Jan 2018 22:02:56 +0000 Subject: Pre-load key UNO mappings. Change-Id: I415e07d737c734d63ac969783464babcbb9ea884 Reviewed-on: https://gerrit.libreoffice.org/48365 Tested-by: Jenkins Reviewed-by: Michael Meeks --- cppuhelper/source/servicemanager.cxx | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/cppuhelper/source/servicemanager.cxx b/cppuhelper/source/servicemanager.cxx index 014b8ea91817..420316c2a5a3 100644 --- a/cppuhelper/source/servicemanager.cxx +++ b/cppuhelper/source/servicemanager.cxx @@ -43,6 +43,7 @@ #include #include #include +#include #include "loadsharedlibcomponentfactory.hxx" @@ -1992,6 +1993,25 @@ void cppuhelper::ServiceManager::preloadImplementations() { } } std::cerr << std::endl; + + // Various rather important uno mappings. + struct { + const char *mpFrom; + const char *mpTo; + const char *mpPurpose; + } aMappingLoad[] = { + { "gcc3", "uno", "" }, + { "uno", "gcc3", "" }, + }; + + static std::vector maMaps; + for (auto &it : aMappingLoad) + { + maMaps.push_back(css::uno::Mapping( + OUString::createFromAscii(it.mpFrom), + OUString::createFromAscii(it.mpTo), + OUString::createFromAscii(it.mpPurpose))); + } #endif } -- cgit