diff options
author | RĂ¼diger Timm <rt@openoffice.org> | 2005-11-11 11:17:07 +0000 |
---|---|---|
committer | RĂ¼diger Timm <rt@openoffice.org> | 2005-11-11 11:17:07 +0000 |
commit | 8020163e4405b1155c7a30ad98433fab49265567 (patch) | |
tree | a4ed82bc964b2a552f3a48d9b2deee8e8480c613 /xmlhelp | |
parent | 2670b025782f1d7488e294ca0db72f0b0641a385 (diff) |
INTEGRATION: CWS c06 (1.17.48); FILE MERGED
2005/08/24 14:59:54 abi 1.17.48.1: #i53539# no basic help, if org.openoffice.Office.Common/Help/ShowBasic is set to false
Diffstat (limited to 'xmlhelp')
-rw-r--r-- | xmlhelp/source/cxxhelp/provider/provider.cxx | 34 |
1 files changed, 30 insertions, 4 deletions
diff --git a/xmlhelp/source/cxxhelp/provider/provider.cxx b/xmlhelp/source/cxxhelp/provider/provider.cxx index 7b8c40276018..94cae2eefb32 100644 --- a/xmlhelp/source/cxxhelp/provider/provider.cxx +++ b/xmlhelp/source/cxxhelp/provider/provider.cxx @@ -4,9 +4,9 @@ * * $RCSfile: provider.cxx,v $ * - * $Revision: 1.18 $ + * $Revision: 1.19 $ * - * last change: $Author: rt $ $Date: 2005-09-09 12:20:03 $ + * last change: $Author: rt $ $Date: 2005-11-11 12:17:07 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -395,7 +395,9 @@ void ContentProvider::init() imageZip += rtl::OUString::createFromAscii("/images.zip"); } - m_pDatabases = new Databases( instPath, + sal_Bool showBasic = getBooleanKey(xHierAccess,"Help/ShowBasic"); + m_pDatabases = new Databases( showBasic, + instPath, imageZip, productname, productversion, @@ -438,7 +440,7 @@ Reference< XMultiServiceFactory > ContentProvider::getConfiguration() const } catch( const com::sun::star::uno::Exception& ) { - OSL_ENSURE( sProvider.is(),"cant instantiate configuration" ); + OSL_ENSURE( sProvider.is(),"cant instantiate configuration" ); } } @@ -502,6 +504,30 @@ ContentProvider::getKey(const Reference< } +sal_Bool +ContentProvider::getBooleanKey(const Reference< + XHierarchicalNameAccess >& xHierAccess, + const char* key) const +{ + sal_Bool ret = sal_False; + if( xHierAccess.is() ) + { + Any aAny; + try + { + aAny = + xHierAccess->getByHierarchicalName( + rtl::OUString::createFromAscii(key)); + } + catch( const com::sun::star::container::NoSuchElementException& ) + { + } + aAny >>= ret; + } + return ret; +} + + void ContentProvider::subst( rtl::OUString& instpath ) const { |