diff options
author | Ivo Hinkelmann <ihi@openoffice.org> | 2010-03-25 17:21:13 +0100 |
---|---|---|
committer | Ivo Hinkelmann <ihi@openoffice.org> | 2010-03-25 17:21:13 +0100 |
commit | a687f59eac4ad98a4b60a4b3add78f33e4dd9166 (patch) | |
tree | 33e9ccf40588c89f5a98a87ae9385c6d8b8f7935 /unotools | |
parent | 2f528025b20854cf918d95f6781b5e2052ddf929 (diff) |
cws l10ntooling18: #i110394# Introduce the variable %OOOVENDOR
Diffstat (limited to 'unotools')
-rw-r--r-- | unotools/inc/unotools/configmgr.hxx | 3 | ||||
-rw-r--r-- | unotools/source/config/configmgr.cxx | 15 |
2 files changed, 17 insertions, 1 deletions
diff --git a/unotools/inc/unotools/configmgr.hxx b/unotools/inc/unotools/configmgr.hxx index 82af190aab4f..c26ff5245739 100644 --- a/unotools/inc/unotools/configmgr.hxx +++ b/unotools/inc/unotools/configmgr.hxx @@ -99,7 +99,8 @@ namespace utl PRODUCTXMLFILEFORMATVERSION, WRITERCOMPATIBILITYVERSIONOOO11, OPENSOURCECONTEXT, - ABOUTBOXPRODUCTVERSION + ABOUTBOXPRODUCTVERSION, + OOOVENDOR }; //direct readonly access to some special configuration elements static com::sun::star::uno::Any GetDirectConfigProperty(ConfigProperty eProp); diff --git a/unotools/source/config/configmgr.cxx b/unotools/source/config/configmgr.cxx index 5f16733b5249..0df6d49afe59 100644 --- a/unotools/source/config/configmgr.cxx +++ b/unotools/source/config/configmgr.cxx @@ -70,6 +70,8 @@ namespace : public rtl::Static< ::rtl::OUString, ProductVersion > {}; struct AboutBoxProductVersion : public rtl::Static< ::rtl::OUString, AboutBoxProductVersion > {}; + struct OOOVendor + : public rtl::Static< ::rtl::OUString, OOOVendor > {}; struct ProductExtension : public rtl::Static< ::rtl::OUString, ProductExtension > {}; struct XMLFileFormatName @@ -433,6 +435,14 @@ Any ConfigManager::GetDirectConfigProperty(ConfigProperty eProp) return aRet; } + rtl::OUString &rOOOVendor = OOOVendor::get(); + if ( eProp == OOOVENDOR && rOOOVendor.getLength() ) + { + aRet <<= rOOOVendor; + return aRet; + } + + rtl::OUString &rProductExtension = ProductExtension::get(); if ( eProp == PRODUCTEXTENSION && rProductExtension.getLength() ) { @@ -493,6 +503,7 @@ Any ConfigManager::GetDirectConfigProperty(ConfigProperty eProp) case PRODUCTXMLFILEFORMATNAME : case PRODUCTXMLFILEFORMATVERSION: case OPENSOURCECONTEXT: + case OOOVENDOR: case ABOUTBOXPRODUCTVERSION: sPath += C2U("Setup/Product"); break; case DEFAULTCURRENCY: sPath += C2U("Setup/L10N"); break; @@ -526,6 +537,7 @@ Any ConfigManager::GetDirectConfigProperty(ConfigProperty eProp) case PRODUCTNAME: sProperty = C2U("ooName"); break; case PRODUCTVERSION: sProperty = C2U("ooSetupVersion"); break; case ABOUTBOXPRODUCTVERSION: sProperty = C2U("ooSetupVersionAboutBox"); break; + case OOOVENDOR: sProperty = C2U("ooVendor"); break; case PRODUCTEXTENSION: sProperty = C2U("ooSetupExtension"); break; case PRODUCTXMLFILEFORMATNAME: sProperty = C2U("ooXMLFileFormatName"); break; case PRODUCTXMLFILEFORMATVERSION: sProperty = C2U("ooXMLFileFormatVersion"); break; @@ -565,6 +577,9 @@ Any ConfigManager::GetDirectConfigProperty(ConfigProperty eProp) if ( eProp == PRODUCTVERSION ) aRet >>= rProductVersion; + if( eProp == OOOVENDOR ) + aRet >>= rOOOVendor; + if ( eProp == ABOUTBOXPRODUCTVERSION ) { aRet >>= rAboutBoxProductVersion; |